Migrate a Node.js app from JavaScript to TypeScript | Tips for gradual adoption

แชร์
ฝัง
  • เผยแพร่เมื่อ 21 ก.ย. 2024
  • Learn how to gradually migrate a Node.js application from JavaScript to TypeScript.
    In this video, I cover the the following:
    - How to set up a tsconfig.json file.
    - How to fix TypeScript errors when converting JS files to TS.
    - How to use a combination of CommonJs and ES6 modules with esModuleInterop configuration.
    - How to use a hybrid approach of TypeScript and JavaScript using allowJs configuration.
    - How to set up custom type definitions for NPM packages by declaring modules.
    - How to convert unit tests written using mocha and chai to TypeScript.

ความคิดเห็น • 12

  • @UsefulProgrammer
    @UsefulProgrammer 3 ปีที่แล้ว +3

    Thanks Ambient Coder - This was quite a great way for me to learn TypeScript.

  • @rorycawley8334
    @rorycawley8334 3 ปีที่แล้ว +4

    Excellent video, please make more

  • @visionary_3_d
    @visionary_3_d ปีที่แล้ว

    Great video. Thanks for sharing.

  • @alexandre3932
    @alexandre3932 2 ปีที่แล้ว +1

    Thank you, it will help me a lot to migrate my personnal projet.

  • @JenHamon
    @JenHamon ปีที่แล้ว

    This helped me a lot. Thank you!

  • @laxmiz
    @laxmiz 2 ปีที่แล้ว +2

    Can you provide access to sample code explained here in this video

  • @Scetils
    @Scetils 3 ปีที่แล้ว +3

    Nice. Do you have tips on setting up eslint to not be so aggressive while converting a project across?
    Is there a balance between adding 1000 linting rules while still make sure eslint is useful and not a false confidence liability to the overall project?

    • @ambientcoder5462
      @ambientcoder5462  3 ปีที่แล้ว +1

      Good question! It really depends on your project preferences. I’d recommend that you label them as warnings. This allows developers to be aware of the tech debt but also doesn’t prevent them from progressing on immediate work.

  • @kacperkepinski4990
    @kacperkepinski4990 11 หลายเดือนก่อน

    what is dist?

  • @arupde6320
    @arupde6320 2 ปีที่แล้ว

    why r u not uploading??

  • @pluraltest9242
    @pluraltest9242 2 ปีที่แล้ว +1

    lol usually has tests we yolo