fabien0102 / gatsby-starter

Gatsby 2.0 starter with typescript and many cools dev tools
386 stars 99 forks source link

Adds tslint as a dev dependency #41

Open vitkon opened 6 years ago

vitkon commented 6 years ago

If TSLint is not installed globally, it will not lint in IDE local tslint installation fixes it

fabien0102 commented 6 years ago

Deploy preview ready!

Built with commit 5a99ddb6a80af4204e835aa9ad546dde7193db4b

https://deploy-preview-41--fabien0102-gatsby-starter.netlify.com

fabien0102 commented 6 years ago

It's strange, we have already a ts-lint dependency and you add tslint (I need to check the difference between the both), and AppVeyor should not like this tslint 😞

npm ERR! Windows_NT 6.3.9600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "lint"
npm ERR! node v6.12.0
npm ERR! npm  v3.10.10
npm ERR! code ELIFECYCLE
npm ERR! gatsby-starter@1.0.0 lint: `npm run lint:ts && npm run lint:md && npm run lint:js && npm run lint:css`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the gatsby-starter@1.0.0 lint script 'npm run lint:ts && npm run lint:md && npm run lint:js && npm run lint:css'.
vitkon commented 6 years ago

didn't realise there are 2 modules: tslint and ts-lint. It's just my VS Code linting only started to work when I added tslint

So you know what's the difference between these modules?

fabien0102 commented 6 years ago

@vitkon mmm, so maybe try to totally replace ts-lint by tslint. I want to have the actual lint-staged hook working and the npm run ts:lint also working :wink:

garthk commented 6 years ago

@fabien0102 ts-lint is a typosquat version of tslint, stuck back at version 4.5.1 (cf 5.9.1). ~Not sure if it's safe or not.~ I'd switch.

Update: I've confirmed ts-lint is a clean build of palantir/tslint@ee721bb, but I'd still switch to tslint for updates and peace of mind.

fabien0102 commented 6 years ago

@garthk Perfect, so you can remove and replace totally ts-lint by tslint in this PR and I approve this :wink: