Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update ESLint to use .eslintrc.js #177

Open
rvarbanov opened this issue Apr 26, 2016 · 8 comments
Open

Update ESLint to use .eslintrc.js #177

rvarbanov opened this issue Apr 26, 2016 · 8 comments

Comments

@rvarbanov
Copy link

On the ESLint site they say that .eslintrc is deprecated and that we should use one of the following in that order:

  1. .eslintrc.js
  2. .eslintrc.yaml
  3. .eslintrc.yml
  4. .eslintrc.json
  5. .eslintrc (deprecated)
  6. package.json

I could just update the eslint's settings.json to one of those, but that did not seem to work well for me. Is there a way to update the Interactive Linter to look for one of those files?

@MiguelCastillo
Copy link
Owner

Ah ok. Yeah, it is about time we updated eslint... Would you be interested in submitting a PR to update ESLint and the config?

@rvarbanov
Copy link
Author

I could, but it is not working. That is why I submit an issue and not just a PR 😄

I guess I could submit a PR with the eslint.js only... Is that what you are thinking of?

When I updated the settings.json file to look for .eslintrc.js I started getting errors, but it worked with .eslintrc

@MiguelCastillo
Copy link
Owner

i would submit a PR just to update ESLint... We can tackle the other problem separately.

But why is your .eslintrc a .eslintrc.js and not a .eslintrc.json?

@rvarbanov
Copy link
Author

ESLint supposed to look for .eslintrc.js first and also I like single quotes better 😃

@MiguelCastillo
Copy link
Owner

Currently, i only support JSON. Which means that you really cant use single quotes; it has to be valid JSON :/

@MiguelCastillo
Copy link
Owner

Also, I know this isn't obvious at all. But I run an independent version of ESLint in a worker thread. So ESLint does not really load the configuration files itself when you are working with Interactive Linter. This is one of the reasons I was saying in the other thread why I need to rethink this whole thing. :)

@rvarbanov
Copy link
Author

rvarbanov commented Apr 26, 2016

Right, and that is why I created the issue. It would be nice if there is a way to allow for an array of settingsFiles. I do not know if that is achievable.

Again, I do not know much about how the brackets extensions work so I am only suggesting how it could be improved but have no idea how to do it :)

@MiguelCastillo
Copy link
Owner

right. I completely missed that's what you were saying. sorry about that!

fair enough. it is a great suggestion. moving to running the native eslint will allow us to specify eslint configurations in whichever way you want. That's ultimately what we probably should do.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants