top | item 19651529

(no title)

hansflying | 6 years ago

Very biased article and by the way, tslint will also warns you if you don't use promise:

https://palantir.github.io/tslint/rules/no-floating-promises...

discuss

order

hansflying|6 years ago

ABSOLUTELY EVERYTHING in this article is wrong. I just opened a typescript project in VSCode, created unused function and a class method and I immediately get warning that they are unused. So the author can't even check the facts before writing an article...

steve_taylor|6 years ago

TypeScript is definitely a first-class citizen on VSCode. I’m considering TypeScript in my next React project and will definitely consider using VSCode instead of WebStorm. I’m a long time WebStorm user and ES6+React developer. TypeScript looks like it can solve a lot of my pain points and it supports JSX syntax (TSX).

tom_|6 years ago

Of course it's biased, it's a "Why I XXX" article ;) - what did you expect?

Regarding the floating promises warning, this setting is off by default, so you have to know it's there to activate it. Additionally, VSCode's integration with tslint output is mystifyingly poor, and I assume it is this that the author is referring to. There's clickable output in the build output window, but no popups in the text editor.

I like to run the compiler and linter manually, so I can see all the issues in one list. Popups in the editor are handy but clickable output in the build output window is good enough.

Some people prefer to work with file watchers, so the error/linter output is not as accessible. They probably need to be able to see everything in the text editor. But even if you work the way I do, you may well wonder why you don't get tslint editor popups. I've certainly wondered it myself. I can do without, but they're certainly handy.

novaleaf|6 years ago

I don't think it's deliberately biased, just a guy who's not very invested into the VSCode/Typescript ecosystem who's going back to his known tools.

FYI TSLint still has a large amount of config required to get it working, and the vscode integration still has a "wont-fix, upstream" bug where it won't lint files unless they are open in the editor. So you need to manually run tslint from the commandline. See: https://github.com/Microsoft/vscode-typescript-tslint-plugin...

I'm guessing that webstorm does this this more auto-magically for the user.