idmitriev / eslint-plugin-better Goto Github PK
View Code? Open in Web Editor NEWAvoid some language features to write better code
License: MIT License
Avoid some language features to write better code
License: MIT License
allow switches of the form:
switch(expr) {
case (expr): return expr;
...
default: return expr;
}
eg every switch must have a default return expr, every case must have a return expr.
then it's sort of like a match expression.
I want to start to use the defaults but I keep getting weird errors. I get all sorts of config schema errors if I use "plugin:better/recommended" or "plugin:better" or "plugin:better/all" in the extend block and I get "definition for (x) not found" for all definitions if I add the .eslintrc into the extend block.
What's the best way to have the defaults in my .eslintrc.js?
Thank you
What's the justification around the no-exceptions rule? If I want to create pure functions, there are a few functions that throw, and I need to catch to ensure the function remains pure... or just let it blow up inside a Promise which doesn't really help me get finer grained error information.
Thanks for this library, btw!
As per jfmengels/eslint-plugin-fp#30, this package and eslint-plugin-fp
have a bit of overlap since most of your rules are about enforcing functional programming. Since both projects are MIT licensed, it would be great to merge this into eslint-plugin-fp
if you're comfortable with this. While I don't maintain that package, I'd be happy to help integrate them if you'd like.
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.