merkle-open / eslint-config Goto Github PK
View Code? Open in Web Editor NEWDefault configurations for eslint
License: MIT License
Default configurations for eslint
License: MIT License
Hey,
I don't always want to add JSdoc comments to constructor
, render
and all the lifecycle methods.
Could we please ignore those methods?
Looks like @Dash4 is not maintained anymore. We should think about removing this package/functionality. In additional: currently it introduces vulnerabilities in our dependencies (moderate).
With the release of v0.9.3 the version of the typescript eslint plugin and parser got an update from 3.10.1
to 4.8.1
(see here.
It seems that with v4 of typescript-eslint you now have to manually define globally defined namespaces in your configuration file (see Typescript-eslint FAQ reference).
If you do not do this, eslint will throw no-undef
related errors although the namespaces are accessible over typescript, e.g.:
const CustomTag = props.tag as keyof JSX.IntrinsicElements; // --> 'JSX' is not defined. eslint(no-undef)
So: Does it make sense to apply the recommendation of typescript-eslint, and automatically opt out of the no-undef
rule altogether as soon as we are using our typescript related configurations?
currently dynamic import's failing because there is no parser defined.
Comma dangle decreases the quality of git-history and tends to cause merge conflicts as you have to change lines although you are not changing it.
The rule comes from >=IE7 because IE used to handle the comma dangle as syntax error.
For IE8+/Chrome/FF/Safari/Node that's not and issue anymore.
Do you see further benefits to follow this rules?
I would suggest to turn this rule off.
example:
AppNavDrawer.propTypes = {
docked: PropTypes.bool.isRequired,
style: PropTypes.object,
onRequestChangeNavDrawer: PropTypes.func.isRequired
};
current config:
'react/sort-prop-types': [2, {
ignoreCase: true,
callbacksLast: true,
requiredFirst: true
}],
Create pluggable ESLint configuration for Angular projects as part of the @namics/eslint-config.
First evaluate if this is a good idea. Maybe use recommendations from Angular itself.
JSX is getting used by other libraries as for now VueJS.
If using a mono-repository with hoisting it will lead to a typescript conflict where it is not able to simultaneously extend "Element" with ReactElement and VNode.
Could we move @types/react and @types/react-dom to devdeps. or create separate packages for different libraries e.g. (@namics/vue-eslint-config)?
Would love to contribute.
I like the idea of showing tips and improvements into linting errors or warnings. See: https://addyosmani.com/blog/disallow-imports/
What do you think about adding:
messages
into our rules. Maybe better only on project basis as a custom rule โ because there is a wide range of potentially big libraries out there?At the beginning of October the new version 8 of eslint was published.
We should either note in peerDependencies that the configuration should be used up to eslint verison 7 or ensure compatibility to version 8
Would it make sense to have eslint 4 support?
Probably it's not that easy, plugins also have to be updated: http://eslint.org/docs/4.0.0/user-guide/migrating-to-4.0.0
What do you think?
Does it make sense to have eslint 5 support?
Migration Guide eslint 5
What do you think?
By using webpack with dynamic imports you can use a inline comment to name the file:
const { wait } = await import(/* webpackChunkName: "wait" */ './wait');
Eslint config does not allow this becauseno-inline-comments
is enabled
No. 2:
Some days ago eslint version 6 was released.
Since there are some breaking changes we should invest some time to make tis configuration compatible.
Create pluggable ESLint configuration for Vue.js projects as part of the @namics/eslint-config.
I'm getting this error when using this config with node 4.x and matching npm version 2.x:
Error: Failed to load plugin import: Cannot find module 'eslint-plugin-import'
Referenced from: @namics/eslint-config/configurations/es6-browser.js
Referenced from: <...>/.eslintrc.js
at Function.Module._resolveFilename (module.js:325:15)
the flat structure of npm 3 seems to fix the problem
but i couldn't find a fix for npm 2
what to do?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.