TSLint will be deprecated. Migration to typescript-eslint / #kansaits 2

TSLint will be deprecated. Migration to typescript-eslint / #kansaits 2

5cf7e9533a457726cd51232e06c1da9a?s=128

Masashi Hirano

September 06, 2019
Tweet

Transcript

  1. TSLint will be deprecated Migration to typescript-eslint Masashi Hirano @shisama

    kansai.ts #2
  2. ฏ໺ ণ࢜ / Masashi Hirano αΠϘ΢ζגࣜձࣾ ɹɹ ϑϩϯτΤϯυΤΩεύʔτνʔϜ @shisama_ @shisama

    Node.js Core Collaborator ؔ੢NodeֶԂOrganizer
  3. Agenda • TSLint Roadmap • typescript-eslint • Migration to typescript-eslint

  4. https://palantir.github.io/tslint/

  5. TSLint • TypeScript༻ͷ੩తղੳπʔϧ • CLIΛ࣮ߦ͢ΔͱTypeScriptͷϑΝΠϧͷղੳΛͯ͠ఆٛͨ͠ ϧʔϧΛνΣοΫ͢Δ͜ͱ͕Ͱ͖Δπʔϧ • Πϯσϯτͱ͔ίʔυͷελΠϧͷνΣοΫͳͲ • ϩδοΫͷෳࡶ౓ͳͲ΋νΣοΫͰ͖Δ

  6. ΊͬͪΌศརͳΜ͚ͩͲɺ 2019೥ϝϯςφϯεΛऴྃ͠·͢

  7. https://github.com/Microsoft/TypeScript/issues/29288

  8. https://github.com/Microsoft/TypeScript/issues/29288 54-JOU͸ύϑΥʔϚϯε͕ѱ͍ɻΞʔΩς Ϋνϟ্ʹ໰୊͕͋Δ͔Β5ZQF4DSJQUͱͯ͠͸ &4-JOUΛ࢖͍ͬͯ͘Α

  9. https://github.com/palantir/tslint 54-JOUXJMMCFEFQSFDBUFETPNFUJNFJO

  10. https://github.com/palantir/tslint/issues/4534

  11. https://github.com/palantir/tslint/issues/4534

  12. TSLint Roadmap • 2019/8/1ɾɾɾίΞͷϧʔϧ௥ՃΛετοϓ • 2019/11/1ɾɾɾػೳ௥Ճɺϧʔϧ֦ுΛετοϓ • 2020/1/1ɾɾɾηΩϡϦςΟҎ֎ͷߋ৽Λ͢΂ͯετοϓ • 2020/12/1ɾɾɾ͢΂ͯͷPull

    Requestͷड෇Λετοϓ
  13. https://github.com/typescript-eslint/typescript-eslint

  14. typescript-eslintͱ͸ • TypeScriptΛESLintͰνΣοΫ͢ΔͨΊͷϓϥάΠϯͳͲΛ؅ཧ ͍ͯ͠Δ • ESLintνʔϜͱTypeScriptνʔϜ͕ڠྗ͍ͯ͠Δ • ΋ͱ΋ͱ͋ͬͨeslint/typescript-eslint-parserͳͲ͸Deprecated

  15. https://teppeis.hatenablog.com/entry/2019/02/typescript-eslint UZQFTDSJQUFTMJOUͷ࢖͍ํͳͲ͸ͪ͜Β΁

  16. Migrate to typescript-eslint • ҎԼͷύοέʔδ͕ඞཁ • @typescript-eslint/eslint-plugin • tslint.jsonΛ.eslintrcʹॻ͖׵͑Δඞཁ͕͋Δ

  17. https://teppeis.hatenablog.com/entry/2019/02/typescript-eslint QMVHJOTɺQBSTFSɺQBSTFS0QUJPOTͷઃఆ͕ඞཁ

  18. https://github.com/typescript-eslint/tslint-to-eslint-config

  19. tslint-to-eslint-configͱ͸ • tslint.jsonΛ.eslintʹίϯόʔτ͢ΔCLIπʔϧ • typescript-eslintνʔϜ͕։ൃ • ੜ੒͢Δܗࣜ͸JSΦϒδΣΫτͱJSONΛαϙʔτ • npx tslint-to-eslint-configΛ࣮ߦ͢Δͱtslint.jsonΛಡΜͰeslintrc.js

    ͱ͍͏ϑΝΠϧΛੜ੒͠·͢
  20. https://qiita.com/shisama/items/b3d63142797b07cb554e ϑΝΠϧ໊ͷࢦఆ΍+40/ग़ྗͳͲ Φϓγϣϯʹ͍ͭͯ͸ͪ͜Β΁

  21. https://qiita.com/shisama/items/b3d63142797b07cb554e ͱ͸͍͑ɺ׬ᘳͰ͸ͳ͍ʂ ੜ੒͞ΕͨFTMJOUSDΛ खͰमਖ਼͢Δඞཁ͕͋ΔͷͰ஫ҙʂ

  22. ·ͱΊ • TSLint࢖͍ͬͯΔਓ͸ૣΊʹESLintʹҠߦ͢Δඞཁ͕͋Δ • ࠓޙ͸typescript-eslint + ESLintͰTypeScriptͷLintΛ͠·͠ΐ͏ • tslint-to-eslint-configΛ࢖͏ͱҠߦ͸ΘΓͱεϜʔζʹ͍͔͘΋ •

    typescript-eslintνʔϜ։ൃͳͷͰվળ͞Ε͍ͯ͘ͷΛظ଴
  23. Thanks. @shisama_ @shisama