Feb 10, 2022
Posted by Patrick Burma

My take on this question is that yes you can upload these packages to the Client Builder and use them but there is a but.

Vantiq’s client builder is essentially a standard web server like Apache or nGinx. It will not be able to run NodeJS code, so your .js files need to be compatible with a regular web server.

There are a couple ways you can do this. The easiest method is to go into the client builder and add the URL or uploaded docs reference as a Custom Asset:


If there are a lot of files it is possible to use “require” and reference a remote URL that points to the base of a script directory and the the relative dir/filenames in the require code but this will not work with Vantiq documents.

See ESRI example: https://developers.arcgis.com/javascript/latest/display-a-map/#add-modules

If you wanted to run node apps with Vantiq you can do this by running a separate node server, and I have an example here that uses the Vantiq nodejs-sdk.


And the last tidbit I’ll mention is that you can upload a Vantiq document as a public document by adding public prefix to the filename when you upload the file:


This would let you run standard HTML on Vantiq but from outside the Client Builder as shown in this Gatsby example:




© Vantiq 2024 All rights reserved  •  Vantiq Corporation’s Privacy Policy and Cookie Policy