Closed OperKH closed 5 years ago
- Add .editorconfig.
I'm not totally against adding this, but I'm also not that interested in it – But I agree with @BridgeAR it should be a separate PR
- Add .prettierrc to be able quick format w/o brakiong es-lint rules.
This projects uses standard, (see devDependencies) - use standard --fix
to reformat
- Add .eslintrc.js to get rid of vars.
why? there's nothing wrong with using vars
- Move "./index.js" to "./src/index.js".
To make build just run
npm run build
it will create./dist
folder with 3 types of modules.Rollup config checks eslint, transpiles ES6+ code to ES5 and uglifies code.
Without build modules I can't use this lib in my project because libraries should be distributed as ES5 code to not break compatibility with <IE11 and because we are always do not compile
node_modules
code.Before this PR I saw
const
in myvendors.js
file.
I would rather convert all code to ES5 manually than introduce transpilation overhead.
Build is more convenient for front-end projects:
Also:
To make build just run
npm run build
it will create./dist
folder with 3 types of modules.Rollup config checks eslint, transpiles ES6+ code to ES5 and uglifies code.
Without build modules I can't use this lib in my project because libraries should be distributed as ES5 code to not break compatibility with <IE11 and because we are always do not compile
node_modules
code.Before this PR I saw
const
in myvendors.js
file.