@holcomb/op-build-tools

Common tools for building and developing Oportun modules and apps

Stats

StarsIssuesVersionUpdatedCreatedSize
@holcomb/op-build-tools
0.0.283 years ago3 years agoMinified + gzip package size for @holcomb/op-build-tools in KB

Readme

ES6/Typescript Build and Development system for Oportun.

once set up run npm start to begin working with a module npm run build will produce a version of the module that can be imported into a legacy app exactly as is done today. ( builds are still a work in progress )

Process to convert a modules.

From within a module you wish to upgarde you will need to do the following

npm install -save-dev @oportun/op-build-tools

Next you can choose to run the op-build-tools installer. This is recomended and automates some of the conversion process, such as setting up your entry point, adding tsconfigs, and removing unused packages/configs

./node_modules/.bin/op-build-tools install

once this is done you should run npm install to make sure dependencies added by the installer are installed. TODO automate this step in the installer

Develop Workflow

While your module is still being used in a legacy app you will want to run grunt serve -l from the legacy app container.

Then from within your module, run npm start this command will prompt you for the Name of the app your working with, select this and press enter. From here you browser will open, and will hot reload as you make changes to the module.

process to convert a module are as follows

Open ./src/index.ts there are some instructions in there if you used the installer, that will help you get your entry point configured.

For all your src files, one by one move them into the ./src directory. import as needed in your entry file.

Remove the IIFE, and add an export default as apropiate for each file

For angular modules we export the .name, for services and factories export the function, for components you export the config object.

rince and repeat until the whole module is converted. In most cases this can be done in a day or two...its easy, but boring and tedius. op-common is a psecial case that will take some time to convert.

If you find any bugs or have a feature request, please open an issue on github!

The npm package download data comes from npm's download counts api and package details come from npms.io.