Install the following if you haven't already.
Click 'Use this Template' on the Github page to make a new repository copied from the template. Clone the new repo.
# Install dependencies in your repo directory
$ yarn
You can use these scripts defined in package.json
.
These scripts build the app in the dist/assets
directory. If you want to run zcli
or zat
manually, run them from the dist
directory.
Build once for local testing:
$ yarn dev
Tell Webpack to watch for changes and re-build:
$ yarn watch
This serves the app from the dist
directory using zcli. Add ?zcli_apps=true
to the end of your Zendesk URL to see the app in Zendesk.
$ yarn serve
The app makes request through Zendesk's proxy server, so it can't connect to zendesk-connector.lightspeedservices.test
.
You can open a tunnel with Expose:
yarn tunnel
Production builds won't work with zlci because it doesn't support secure app settings.
$ yarn prod
To test your app locally, run yarn watch
, yarn serve
, and yarn tunnel
at the same time in two different terminals.
You can set up some IDEs and editors to do this for you with one click.