https://github.com/fengzilong/babel-time-travel
Debug blackboxed babel, with time travel capability
https://github.com/fengzilong/babel-time-travel
babel debug plugin time-travel webpack
Last synced: about 2 months ago
JSON representation
Debug blackboxed babel, with time travel capability
- Host: GitHub
- URL: https://github.com/fengzilong/babel-time-travel
- Owner: fengzilong
- License: mit
- Created: 2021-10-15T12:32:37.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-11-09T16:06:04.000Z (over 3 years ago)
- Last Synced: 2025-04-09T21:44:33.981Z (about 2 months ago)
- Topics: babel, debug, plugin, time-travel, webpack
- Language: JavaScript
- Homepage:
- Size: 896 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# babel-time-travel
[](https://www.npmjs.org/package/babel-time-travel)
[](https://www.npmjs.org/package/babel-time-travel)
[](https://www.npmjs.org/package/babel-time-travel)
Tell you the story about how every babel plugin transform your file inside a blackbox
## Installation
```bash
npm i babel-time-travel -g
```## Usage
`babel-time-travel` will register a global command named `btt` after a global installation
To use it, simply add your own command after `btt`
> Format: btt [options] -- [your-command]
```bash
btt -- npm run build
btt -- babel src --out-dir lib
btt -- ... # any other command
```With options
- --filter
```bash
btt --filter axios/lib -- npm run build
```If babel-time-travel is slow running in your project, you can limit it to only run on certain files by using `--filter` option
Note
- Blackboxed `babel` should run in the same process with your command
- Don't cache any babel transformation result( like babel-loader caching )
- Options like `--filter` should placed before `--`## Thanks
Highly inspired by [babel/babel-time-travel](https://github.com/babel/babel-time-travel) which supports time travel in browser
## License
MIT