question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Linting not running on jsx files

See original GitHub issue

It may be something in my setup, but AFAIK nothing has changed. Linting has stopped running on JSX files, where I am pretty sure it did in the recent past (I got a VSCode update recently)

When I run ./node_modules/.bin/eslint --ext .js,.jsx src test locally it finds issues in .jsx files, however not within the VSCode “Problems” tab

I went into my VSCode settings and have added "eslint.options": { "extensions": [".jsx", ".js"] } and that isn’t helping either.

Am I doing it wrong?

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
cdbcommented, Apr 26, 2017

FWIW, I found out the issue…my *.jsx files were being classified as JSX instead of Javascript React, I believe due to another extension I had added. I removed the extension (but was also fixed by just adding ‘jsx’ to the eslint.validate settings as you had suggested @dbaeumer - thanks!

Had a fun time learning how to run an extension in the Extension Development Host and debug it along the way, which was fun 😃

0reactions
dbaeumercommented, Aug 4, 2017
Read more comments on GitHub >

github_iconTop Results From Across the Web

ESLint configuration for JSX - reactjs - Stack Overflow
In order to lint JSX files configuration alone is not enough. Your configuration looks fine (although you probably don't need babel-eslint ...
Read more >
Linting React JSX with ESLint (in ES6) | egghead.io
We walk through setting up ESLint in a project, using the eslint --init CLI tool with the JSX and ES6 options, writing a...
Read more >
Set up ESLint and lint-staged for JS/JSX/React project - Medium
A linter or lint refers to tools that analyze source code to flag programming errors, bugs, stylistic errors, and suspicious constructs.
Read more >
React Native development tools - Part 1: Linting tools - Pusher
If your text editor shows something similar to the one above, then the linter is working. If not, then it's either you haven't...
Read more >
React JavaScript Tutorial in Visual Studio Code
Linting. Linters analyze your source code and can warn you about potential problems before you run your application. The JavaScript language services included ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found