Closed ek9 closed 7 years ago
I'd prefer we don't use gulp. Maybe we can move the test runner to jest
as it should be a pretty easy drop-in replacement for mocha.
You can base yourself on this other generator for the ESLint setting https://github.com/SBoudrias/generator-jest/blob/master/package.json#L49
Also, if you feel like it, you could also add nsp
check on the same PR given it's pretty similar setup.
Just a quick comment:
There is no reason for eslint --fix to run AFTER the tests have passed. A standard developers workflow is:
Now bringing eslint --fix in between steps 2 and 3 most of the time will introduce undesired changes. --fix
should never be run automatically, especially as a posttest
or pretest
. The reason is simple - you should never combine code styling with functional changes together in one commit.
This commit adds eslintrc support ( #54 )
As we haven't discussed and decided on which code style to use, I have added
xo-space
(https://github.com/sindresorhus/eslint-config-xo-space) config as I believe this one is a decent choice.As it throws a lot of linting errors, before doing refactoring of the code, I would like to get a review if this code is appropriate. We can keep the discussion on #54 issue.
Also, this is a WIP PR, partially based on #56 as it allows for easy integration. If #56 is merged, then this will only be 1 extra commit: https://github.com/ek9/generator-license/commit/7d8f7d683fdbd704ce2e6f00a8d86ce735ee19fa