Include tslib
as a Shared Dependency
#67
Labels
cli
Concerns the piral-cli application.
core
Concerns the piral-core library.
dependencies
Pull requests that update a dependency file
enhancement
New feature or request
Milestone
Description
Currently,
piral-core
(and dependents such aspiral
) usetslib
. As such it should be a no-brainer to also exposetslib
as a shared dependency. This can significantly reduce bundle size.Background
tslib
contains all runtime helpers of TypeScript. These helpers are auto-generated by default, but can be referenced implicitly using the"importHelpers": true
setting in thecompilerOptions
of the tsconfig.Naturally, the tsconfig of a Piral instance / pilets should contain this flag and use the then shared dependency to reduce output sizes.
Discussion
Maybe other shared runtime libs (e.g., for async code the regenerator package comes to my mind) should be shared similarly. Right now, however, it is unclear how its exposed. Potentially, this should therefore be left to the specific Piral instance to decide.
The text was updated successfully, but these errors were encountered: