Package Exports
- @aliser/ts-transformer-append-js-extension
- @aliser/ts-transformer-append-js-extension/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@aliser/ts-transformer-append-js-extension) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Eliminates a need for specifying .js
extension for relative imports of TypeScript files.
Based on typescript-transformer-append-js-extension package by @Zoltu, now using ts-patch for transformer capability.
Installation
Install using npm
.
npm i -D @aliser/ts-transformer-append-js-extension
Usage
- Install
ts-patch
using the instruction from here - Add the transformer to
tsconfig.json
{
"compilerOptions": {
"plugins": [
{ "transform": "@aliser/ts-transformer-append-js-extension" }
]
},
}
- Build your project using
tsc
or run it usingts-node
.