Warning: Wahroo's HTML API is still in beta, more changes are coming!
git clone https://github.com/wcrbrm/wahroo-html-client
<!-- WAHROO EMBEDDING START -->
<script type="text/javascript" src="wahroo-html-client/js/loader.js"
data-url="/vessels/38"></script>
<!-- WAHROO EMBEDDING END -->
Loader.js uses JQuery library and therefore must be inserted only after it.
Installation is finished at that point and can be checked. Please watch errors in console for troubleshooting.
All parameters are optional
Parameter | Description |
---|---|
data-url | Default location inside the web application. |
Example: /charter/102 |
|
data-html-root | Http path to html client distribution |
Example: /wahroo-html-client/ |
|
data-api-root | Http path of the RESTful API |
Example: /api/v1/ |
|
data-container | CSS selector of container to which embedding will be done |
Example: #booking-container |
To customize CSS or Javascript you need to have NodeJS and Grunt installed locally and working from your command line. If they are present, before starting modifications, please do the following:
cd wahroo-html-client
# installs all required dependencies (plugins for grunt)
npm install
# start daemon to watch changes and recompile them on fly
grunt watch
While the deamon is watching your changes, feel free to edit LESS files and Javscript - they will be automatically compiled in minified versions.