Fix types and linting errors
See original GitHub issueAlthough type checking and linting was implemented in the app from the beginning, we disabled it early so that scientists could iterate faster without being bothered too much with the latest web dev novelties.
We need to apply fixes incrementally, a few files a day. Preferably as a part of the routine PRs.
At some point we can re-enable linting on build-time, but currently you can use these commands to run eslint
stylelint
tsc
and tslint
all together in a separate terminal instance:
yarn lint
yarn lint:fix
yarn lint:watch
yarn lint:fix:watch
Or yarn <tool_name>:[fix|watch|fix:watch]
for a specific tool.
Current output:
Eslint
512 warnings found.
400 warnings potentially fixable with the `--fix` option.
tsc:
Found 85 errors.
Note that my linting tastes are somewhat peculiar and controversial: there is a whole lot of eslint and tslint plugins and tsc is configured very strictly. I like it this way, but most developers find it annoying.
Feel free to post your thoughts. We can relax the default config, but I’d like to keep my hard-mode one at leas as an option.
PLEASE do not submit one giant merge conflict. It could not be merged and is a waste of everyone’s time. ⏰
Issue Analytics
- State:
- Created 3 years ago
- Reactions:3
- Comments:14 (14 by maintainers)
@patrikvarga Thanks Patrick! I really enjoyed your focused PRs. It’s a pleasure to see a green merge button on a PR, and yours were all green 😃 Also these have improved quality of code significantly. I am looking forward to see more of your contributions!
@jsmith Absolutely! But careful with moving things around. Maybe tests first? Correctness of the results is of utter importance for this project.