typescript-bundler
v1.0.1
Published
A Zero-configuration TypeScript transpiler and bundler
Downloads
17
Readme
TypeScript Bundler
A Zero-configuration TypeScript transpiler and bundler.
Features
- Transpile
.ts
file to.js
and.d.ts
- Bundle
.js
and.d.ts
output automatically - Inline and treeshaking
sideEffectFree: false
es modules which defined indevDependencies
- Allow multiple
.ts
entries underbin
orlib
folder - Compress the
public
folder withgzip
,br2
andwebp
- Mangle, Prettier output code automatically
- Generate
package.json
for the bundle - Generate
settings.js
from different type of config files - No intermediate files written on disk, keep your project folder clean
- Improve
agentframework
performance
How to use?
- Install
npm i -g git+ssh://[email protected]/e2tox/tsb.git
- Make your project structure similar as following:
Project
|-- bin
| |-- cli.ts
| |-- ...
|
|-- conf
| |-- settings.properties
| |-- settings.yaml
| |-- ...
|
|-- lib
| |-- index.ts
| |-- library.ts
| |-- utils.ts
| |-- ...
|
|-- public
| |-- image.gif
| |-- page.html
| |-- embeded.js
| |-- ...
|
|-- src
| |-- app.ts
| |-- utils.ts
| |-- services
| | |-- users.ts
| | |-- groups.ts
| | |-- ...
| |-- ...
|
|-- index.ts
|-- package.json
|-- tsconfig.json
- run this command at project root
tsb
Supported Configuration Files
- JavaScript File (settings.js)
- JSON File (settings.json)
- YAML File (settings.yaml, settings.yml)
- JSON File (settings.json)
- JSON5 File (settings.json5)
- INI File (settings.ini)
- Properties File (settings.properties)
Report Bugs
https://github.com/e2tox/tsb/issues
Please also include a link to a sample code repository which can reproduce the issue.