Skip to content

Support typescript with --experimental-strip-types  #208

Description

@marco-ippolito

Add this issue to keep track of the work for supporting typescript out of the box, in the PR you can find documentation etc...
The main idea is to use type-stripping.
This is achieved ideally through the use of an external dependency, in my opinion @swc/wasm-typescript.
I would like to have something basic and usable to propose to the public.

Tracking points to discuss:

  • Support commonjs syntax
  • SourceMaps (enabling them with a flag)
  • Type stripping on .cts
  • Add a flag to enable transformation to support TS only features (enums etc...)
  • Extension guessing (.js because of transpilation => but at runtime is a TS)
  • Transpiling .ts files in the node_modules
  • TypeScript linting
  • Externalize swc wasm

Roadmap: #217

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    typescriptDiscussions related to TypeScript

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions