Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update gulpfile.js to use in strict mode #5478

Merged
merged 1 commit into from
May 9, 2018

Conversation

ksokolowski7
Copy link
Contributor

During build a project by gulp there is an error

Error: Error in parsing: "bower_components\chart.js\gulpfile.js", Line 23: Use of future reserved word in strict mode

"package" is a reserved word and cannot be used in strict mode

https://www.w3schools.com/js/js_reserved.asp

gulpfile.js Outdated
@@ -20,7 +20,7 @@ var yargs = require('yargs');
var path = require('path');
var fs = require('fs');
var htmllint = require('gulp-htmllint');
var package = require('./package.json');
var _package = require('./package.json');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it seems odd to me to have one variable with an underscore while none of the others have one. what do you think about calling it pkg instead of _package?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Of course you right :) it's corrected now

@benmccann
Copy link
Contributor

@etimberg this seems like a pretty simple PR. Do you think we really need a second review from simonbrunel or could we just go ahead and merge it to help keep the queue clean?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants