Closed DanielRuf closed 4 years ago
by refactor/modularize branch, what do you mean? do you mean my master branch or something of your own? I want to make sure I understand that, because that might change whether or not the next part is relevant.
there's a section in the report for linting errors. I just now ran the latest versiones6-plato on what I happened to have open in my editor and I see this
when you run the report, open the index.html file you should (hopefully) see reports for
below that is the file-by-file breakdown, you can sort by linter errors
As far as I can tell this feature is working, but I also may be misunderstanding something, did this answer your question @DanielRuf ?
I meant my refactor branch of my website-checks repo which us merged in master.
The CLI does not output / list these errors.
Is this wanted or should we see them? A number does not tell much.
So if there are eslint errors we have to run a standalone version of it and check the code again?
I meant my refactor branch of my website-checks repo which us merged in master.
The CLI does not output / list these errors.
Simian@DESKTOP-V1915NQ MINGW64 /e/Users/Simian/Desktop/Factory Obscura/angst-room (add-intro-stuff)
$ ./node_modules/.bin/es6-plato -r -d ./report src
Processing 449 files
Warning: React version not specified in eslint-plugin-react settings. See https://github.com/yannickcr/eslint-plugin-react#configuration .
Done!
The artifact is the html document I mentioned, it is intended for the user to open it or build it iteratively in ci. By default this is put in the /reports directory, I believe.
Is this wanted or should we see them? A number does not tell much.
Yes, it is wanted. I'll explain.
They are visible in the report. You are correct a number does not tell much, that is why there is more information in the files of the report, let me show you. I'm sure you saw the first page, this is just like a table of contents:
Now click the bar...
Every file generates a report per file. So you can scroll down...
You can see all the lint errors and the gears will show you complexity,etc per function
So if there are eslint errors we have to run a standalone version of it and check the code again?
Sorta, this is not the same thing as say, an eslint command-line tool, where its 'always on' its more of a report. When I'm developing I also use tools like prettier, etc to do code formatting. This is more for a report, such as something that could run over every PR or in CI, or to do some analysis. The linter is included alongside the complexity analysis to improve your ability to review the file.
that said, In the past I've used it as a post hook while running integration tests and that's not bad. For unit tests, there's some effort in generating all the html files. It is not yet so intelligent that it does HMR or diffing and only updating just the files you touched last. I've considered working that out in the past, but that would take a lot of effort, and there is a lot else I'd probably work on with that. I suppose a fast enough machine could do that?
Foe Eslint, I personally use other things to put out info in my command line on every reload. The primary output of this is a 'nice' html report. and also a convenient way to explore a project and get a sense of the state of it in terms of complexity and lint errors, etc.
Does this answer your questions?
https://github.com/DanielRuf/website-checks
In some cases your CLI prints some eslint errors / exceptions (parsing errors) but not for all / normal eslint findings.
You can see all the lint errors
I don't see the one error per file in my case.
So you're saying when you click into one of the individual file reports, you see the gears with the complexity information, but nothing about the lint errors (eye icons)? And this is in a situation where there's known lint errors (as in if you were to run eslint standalone, you'd see the output.)
Is that the problem?
Just trying to zero in on what needs fixing, here.
FWIW the screenshots I posted are based on the master branch right now, I literally just ran the tool on whatever I had open, via the command I showed you. I just checked with running eslint directly and they seem to be at parity for me. If something is wrong can you give me a way to reproduce it?
@DanielRuf reason I'm asking: I'm going to be upgrading to eslint 3 like, pretty soon... if I'm gonna work on that I might as well look then
I have found the bug, I will provide a PR.
I must admit I don't fully understand what the issue was, can you explain the bug? I'd happily check out a PR too, is this so that eslint logs warnings, as well as errors in the console, particularly, or, was this to make the lint errors appear in the files?
In my case (website-checks with the refactor/modularize branch) does not show the linting errors (warnings).
Should es6-plato show them normally?