tszip
tszip copied to clipboard
Todos
This package is still experimental and unreleased, having only been sent to a few people in private or on Twitter. Please leave any thoughts you have on the following issues.
Jest ESM support
This was something I shelved for the moment; it seems an experimental flag will be required.
See: https://jestjs.io/docs/ecmascript-modules
Documentation regarding build process
This can only really be done by me, but the bulk of the logic is handled by @tszip/resolve-imports
, with @tszip/cjs
for cases where require()
is needed.
Optimizing @tszip/resolve-imports
Currently, imports are coerced to absolute paths and then in the Rollup logic, re-transformed back into relative imports, which is wasteful and unnnecessary. Ideally, import specifiers could be left alone, and the import resolution logic could be greatly simplified.
Replacing Rollup or Terser with swc + post-process
The optimal approach would involve an swc pass (currently analogous to TSC) followed by import resolution (currently analogous to Rollup), with the latter written in Rust.