-
Notifications
You must be signed in to change notification settings - Fork 959
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 Functions template files #2919
Conversation
@bkendall FWIW I always choose the no-lint path. I find JS linters to be mostly annoying, but I am maybe in the minority. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One issue, but otherwise this LGTM
@@ -1,7 +1,7 @@ | |||
{ | |||
"name": "functions", | |||
"scripts": { | |||
"lint": "eslint \"src/**/*\"", | |||
"lint": "eslint --ext .js,.ts .", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will this cause eslint to lint compiled js files? I think we don't want that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@joehan I don't think it would, as JS files (apart from .eslintrc.js
) are listed in the .gitignore
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(I've been working on coming back to this but @hithomasmorelli is correct)
Description
tsconfig.dev.json
to the TS+eslint path to appropriately lint.eslintrc.js
.Fixes #2913
As an aside: I wouldn't be opposed to simplifying this further and not offering the no-lint path. Also, we don't have any script for
npm test
, so there's nothing blocking about always including lint (except your IDE might start flagging issues sooner). Food for thought...Scenarios Tested
Sample Commands
firebase init functions