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

make eslint config env agnostic #4

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

make eslint config env agnostic #4

wants to merge 1 commit into from

Conversation

JoshCoady
Copy link

If I understand correctly, the babel parser should only be used if you are using babel, which makes this a little problematic for node projects.

Maybe there should be extensions that are for a targeted env or purpose?

If I understand correctly, the babel parser should only be used if you are using babel, which makes this a little problematic for node projects.

Maybe there should be extensions that are for a targeted env or purpose?
@gangsthub
Copy link
Contributor

Agreed. If you're not compiling your JS, it's not needed. I'll extend this PR to include the parser in the Vue flavor, which is inherited in the Nuxt flavor.

Thanks, Josh, and sorry for the inconveniences 🙏🏽

@JoshCoady
Copy link
Author

no worries, I just had to look up what the default parser is to set it back as a temp workaround :)

parser: 'espree',

@gangsthub
Copy link
Contributor

First time I hear about it! https://github.com/eslint/espree

@JoshCoady
Copy link
Author

I learned about it when I was looking for a way to reset the parser option back to the default (tried null, false, empty string, and 'default' but those were all just ignored)

They dont document that you can set it to 'espree', but I noticed the following and gave it a shot :)

https://eslint.org/docs/user-guide/configuring/plugins#specifying-parser

By default, ESLint uses Espree as its parser.

Copy link
Contributor

@gangsthub gangsthub left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

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

Successfully merging this pull request may close these issues.

2 participants