Comments (4)
So I think we should just add a variable parameter to the rake task. When we do rake test
, we can do
rake test TEST=path/to/my_test.rb TESTOPTS='--name=test_a_feature'
So I'm thinking we could add something so you can do
rake eslint:run ESLINTOPTS='--cached'
The only downside I see is that we probably should not mirror this capability in the web interface because I haven't thought of a good way to do it yet. Also, maybe people don't use the web interface?
from eslint-rails.
I certainly love the web interface when I am manually fixing warnings/errors by hand. It helps a lot, and reduces the strain of having to read terminal output, which isn't always pretty.
I do wish there was an easier way to provide flags, and think it is critical considering eslint can attempt to auto correct issues with the --fix
flag. Rubocop has an excellent way of handling flags like that, and I would very much like to see this be a thing with eslint-rails.
from eslint-rails.
I will consider taking a look at this perhaps contributing in order to make this a reality 😎🤔🍻
from eslint-rails.
So I forked this repo and wrote in code to allow for auto-correction, as well as a few more goodies. Seeing as this repo isn't really being actively maintained, I will keep the fork separate unless it is desired that they be merged.
New features include
- updated readme
- updated eslint
- autocorrection feature
- different exit statuses based on eslint.json settings. If you have a rule set to error, the build will exit 1. If it is set to warning and no errors exist, it will exit 0
- updated the controller to not break if you don't provide
force_deafult
- updated the web interface to allow you to use autocorrect, or not
- updated the rake tasks
- updated the before_filter to be before_action, since the former was deprecated
I'll be continuing my own support for this in my free time, and intend to include many more features and improvements :)
from eslint-rails.
Related Issues (19)
- Possibility to use custom config file HOT 4
- handling unexpected errors (with no ruleID) HOT 1
- removing / replacing rules in eslint.json that are not in version 2.3.0
- eslint.json `plugin` not working HOT 1
- Print source filename HOT 1
- Handle linting of erb files
- NoMethodError: undefined method `extname' for "/.../../asset.gif":String HOT 5
- how to use airbnb pattern? HOT 3
- How to autocorrect issues ? HOT 1
- RFC: Support for eslint-plugin-compat
- rake eslint:run_all does not work
- rake eslint:run_all or rake eslint:run[filename] not working HOT 1
- Support for .eslintrc.yaml, etc. file formats?
- Undefined method "strip_heredoc" post installation of eslint-rails HOT 2
- Support for multiple files at once
- Rails Sprockets Integration (Vendor assets getting linted) HOT 3
- Upgrade version of ESLint HOT 1
- Include instructions for generating ESLint lib in README HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eslint-rails.