CRA eslint rules that are safe to disable with ReScript

I am new to ReScript and have been reading the docs and this forum a lot lately. I really like the language and the community. Everyone involved, thank you!

I am learning it by doing a CRA project with eslint and I keep getting various warnings. Some of them I know I can safely dismiss, like no default case on a pattern match that has compiled without rescript warnings. But I have been wondering if warnings like ‘no unused expressions’ are normal, or do I need to fear the useEffect missing dependencies warning when we have a separate hook version for the length of the dependency array?

Also, do you employ a default .eslintrc config with safe to ignore rules?

Similar to the response to another thread

Just don’t run eslint on the generated files. Any rules that you might disable to stop the warnings are probably still useful to have on for the rest of your code.

1 Like

I find eslint hooks rules to be useful to run on generated files


i guess one needs to configure a separate eslint config just for ReScript generated files that only contain the hook rule.

All the other mostly code-style related rules are mostly irrelevant for the generated output.

Personally I’d recommend using ViteJS instead. Adding ReScript causes less friction, the fast refresh works reliably well, and you don’t have to deal with a ton of weird over-generalized conventions.