Linter does not warn about lack of constructor arguments.
The vscode shows that there are no arguments, but linter does not show it as an error:
and nothing else...
deno.jsonc:
Help me to make a correct
deno.jsonc
config. Thanks!![No description](https://cdn.answeroverflow.com/1182400681836027914/image.png)
7 Replies
That's because this is a type error not a linting error. To know how many arguments a function or a class constructor receives you need to know about its type. Knowing the type requires far more knowledge than what a linter has access to. Type checks are typically done via
deno check
I see that
deno check
can only process a specific file. How to check the whole folder? Is it possible to combine lint & check output? Is there an abstraction in deno for this?iirc you can pass a glob like
deno check **/*.ts
after that I found my code full of undefined errors, but runtime (
deno run -A src/main.ts
) does not show anything about this. How to preserve runtime to strict check code before run?you can pass
--check
to deno run
thank you so much!
It looks like
deno check **/*.ts
doesn’t respect the "exclude" from deno config file (unlike lint and fmt). Is it something expected?
In my situation I have 10 sub-folders with deno/TS code and more 5 folders. I’m wondering what’s a good way to type-check those 10 folders.