Client module formats
Output format
Warp supports several formats to generate the JavaScript client:
umd
Universal Module Definition (UMD) is capable of working everywhere, be it in the client, on the server or elsewhere.
It can be useful to import the client with an HTML <script>
tag.
npx warp build --output umd:./client/src/module-client.js ./server
node-module
Use it to generate a npm module with its package.json
.
The path has to be the target directory containing the node_modules
directory.
npx warp build --output node-module:./client/ ./server