Package Exports
- byots
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 (byots) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Bring your own TypeScript
Use the latest TypeScript, with complete access to the compiler API 🌹
Kudos to the TypeScript team for maintaining all the code that this project depends on. This project is just a minor automation on top.
Reasons Why:
- Releases everyday.
package.json
links you to typescript definitions- Super Nice: We expose the internal APIs (the ones that have
/* internal */
) - Super Nice: We expose the global
ts
variable. Justrequire('byots')
once and start usingts
like you are in the actual compiler source code. - Super Nice: Converts
const enum
in the compiler definition toenum
. This decreases the typescript compiler version dependence on your dev tools TS->JS emit. - Takes
typescript@next
as a peer dependency and just re-exports it.
Install
In your package.json
npm install byots@latest --save --save-exact
Each release is named after the day it was built and the git commit hash in Microsoft/TypeScript/master that it was built from. We recommend adding save-exact
so you know exactly what you tested with.
Usage
Require
Use require('byots')
and you get what typescript
would give you.
Global ts
In addition to returning what typescript
returns we also expose ts
as a global.
declare var require: any;
require('byots');
console.log(ts.createScanner);
Which makes it easy to use the compiler API if you are using it heavily. Note you only need to require
once from any file.
About
Note that this is a personal endeavor, not officially by Microsoft.