Skip to content

unepwcmc/cites-checklist

Repository files navigation

CITES Checklist

Development

We're using Ember.js with Ember Data to handle REST backend requests. The search & downloads functionality is implemented in Species+, this is just the front-end.

Old Ember resources - relevant to the version of Ember used in the Checklist

More up to date Ember resources - relevant to the much needed upgrade

Important Vendor Note

We are using a customised version of Twitter Bootstrap Typeahead. There should be little need to upgrade in the future due to the simplicity of the library, however should it be necessary then a good read through bootstrap.js beforehand is required to see what needs to be kept.

Setup

In order to install libv8 and therubyracer on MacOS:

$ brew install v8@3.15
$ bundle config build.libv8 --with-system-v8
$ bundle config build.therubyracer --with-v8-dir=$(brew --prefix v8@3.15)
$ bundle install

On Ubuntu, bundle install is sufficient.

Assets are pre-compiled with rake pipeline and served statically:

bundle exec rakep build

For development use the built in server:

bundle exec rakep server

As this is a pre-compiled static page setup that uses HTML5 pushState, you need to setup your server to redirect requests to the index page. In Apache this should work automatically with the included .htaccess file, however for nginx you must add a rule to your server directive to do this:

rewrite ^(.+)$ /index.html last;

You can turn off pushState, however, in config.js.