@genesislcap/build-kit
v14.228.0
Published
Build utilities & types
Downloads
11,136
Readme
Build Kit
Provides utilities and Typescript interfaces to enable a consistent API for different bundlers and other build-related tools.
To provide support for a new bundler:
- create a new NPM package (typically called
*-builder
e.g.xyz-builder
) - add any dependencies required
- provide a default export - function accepting build context xwparameter:
(ctx: BuildContext) => {
// any logic specific to this builder (library API calls, CLI execution etc.)
}
Build context contains user configuration, CLI command details (dev/prod/analyze etc.) and other relevant runtime information.
See @genesislcap/ts-builder for an example.
Development SSL Certificates
@genesislcap/build-kit
bundles a localhost.crt
and localhost.key
file which bundlers may apply to their development server options.
import { getDevCertOptions } from '@genesislcap/build-kit';
...
{
options: getDevCertOptions(),
}
Please follow the Development-SSL-Certificate guide to complete local machine setup.
Installation
To enable this module in your application, follow the steps below.
- Add
@genesislcap/build-kit
as a dependency in yourpackage.json
file. Whenever you change the dependencies of your project, ensure you run the$ npm run bootstrap
command again. You can find more information in the package.json basics page.
{
...
"dependencies": {
...
"@genesislcap/build-kit": "latest"
...
},
...
}
API Docs
License
Note: this project provides front-end dependencies and uses licensed components listed in the next section; thus, licenses for those components are required during development. Contact Genesis Global for more details.
Licensed components
Genesis low-code platform