@@ -5,6 +5,8 @@ Vereign’s JavaScript library is an asynchronous library that allows for digita
## Development
### Running
Run `make dev` to enter development mode. Library will be built with all Restful API endpoints and served from `localhost:9000`. If you edit JS libs code, it will be reloaded on the fly.
- Client being served from `http://localhost:9000/viamapi-client.js`
...
...
@@ -14,6 +16,13 @@ You can specify these URLs in the clients.
If you have to do changes in `main.go`, you need interrupt current process and do `make dev` again.
### CORS
Since libs and restful-api being served within different ports during the development,
it worth mention that responses from restful-api in dev mode must include `"Access-Control-Allow-Origin": "http://localhost:9000"`
and `"Access-Control-Allow-Headers": "*"` headers.
## Building
Run `make` and get client library and iframe bundles from `javascript/dist`