3 ms·
"We wanted to build our dashboard in JavaScript to separate the both front-end and back-end development as well as leverage the power of Balanced’s RESTful API.
by Kiro 13y ago
"We wanted to build our dashboard in JavaScript to separate the both front-end and back-end development as well as leverage the power of Balanced’s RESTful API."
Does this mean they have a back-end layer before the REST API or is the front-end communicating with the API directly?
- mjallday 13y agoHi Kiro, We wrote a simple Python back-end service that stores authentication information -- if you think of the dashboard as a rich client, it needs some way to persist some items that are unrelated to the API such as email address and password login credentials, so that's what this simple service does. However, Balanced's API has CORS-support enabled, so we can make API calls to the API from the Ember app directly (no need to proxy through a back-end service). This will reduce latency to the user to give a perceived feeling of responsiveness once implemented. Interestingly, simply implementing the dashboard as an AJAX app and having the requests fire in parallel as opposed to serially with our existing dashboard has already given a massive performance boost.