@tririga/tri-bundler
Version:
A tool for bundling Polymer 3 TRIRIGA UX views.
45 lines (29 loc) • 2.29 kB
Markdown
# tri-bundler
A tool for bundling a Polymer 3 TRIRIGA UX view into a single output component file.
### Installation
$ npm install @tririga/tri-bundler -g
### Synopsis
$ tri-bundler
### Options
* `-u, --user user` The user name of your TRIRIGA user. Required.
* `-p, --password password` The password for your TRIRIGA user. Required.
* `--url url` The URL of the TRIRIGA server. It must include the context path. Required.
* `--basicuser user` The user name for basic authentication.
* `--basicpassword password` The user password for basic authentication.
* `-v, --view view_name` The name of the view to be bundled. Required.
* `--component file` The root component filename of the view you want to bundle. Required.
* `--output file` The output component filename that will be generated after bundling. Required.
* `--compile-es5` Compile the bundled file to Javascript ES5. Optional.
* `--unique-svg-ids` Assign unique IDs to all TRIRIGA SVG icon elements in the bundled file. Optional.
* `--version` Print tri-bundler version.
* `-q, --quiet` Do not print any non-error message to the console.
* `-h, --help` Print this help information.
### Usage
1. Bundle the Polymer 3 my-ux-view
`$ tri-bundler -u myUserName -p myPassword --url http://someHostName:9080/someContext -v my-ux-view --component my-ux-view-dev.js --output my-ux-view.js`
2. Bundle the Polymer 3 my-ux-view with a relative directory path
`$ tri-bundler -u myUserName -p myPassword --url http://someHostName:9080/someContext -v my-ux-view --component my-ux-view-dev.js --output output/my-ux-view.js`
3. Bundle the Polymer 3 my-ux-view with unique-svg-ids flag
`$ tri-bundler -u myUserName -p myPassword --url http://someHostName:9080/someContext -v my-ux-view --component my-ux-view-dev.js --output my-ux-view.js --unique-svg-ids`
> [!WARNING]
> If you are using the `--unique-svg-ids` option, ensure that you specify the TRIRIGA icon set prefix (for example, `<triplat-icon icon="ibm:attachment">` instead of `<triplat-icon icon="attachment">`). Omitting the prefix will cause the build process to fail to resolve and update icons correctly.