The source code for the project is written in Coffeescript.
The source needs to be completed by writing a od_config.coffee file to define configuration parameters, primarily related to authentication. Use the template file 'od_config_template.coffee' by following its instructions.
The source also needs to be compiled into Javascript and minimized on a development machine before executable code can be deployed on a production server.
A. Prerequisites, development machine
Install nodejs.org
Install node packages
B. Production Deployment
Put yourself at top-level project directory.
Compile source files from Coffeescript to Javascript
(long form)
(short form)
Minify Javascript files
Deploy minified files to production server
On production server:
C. Configuration of Web Service
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.1.10/require.min.js" data-main="[% ctx.media_prefix %]/js/ui/default/opac/overdrive.js">
LoadModule proxy_http_module /usr/lib/apache2/modules/mod_proxy_http.so
D. Web Browser
Reload the browser at http://libraryname.servername.domainname/eg/opac/home, to run the home page of the OPAC. Ensure that the browser's cache is disabled. By monitoring the network traffic, you should see new JS and CSS files load, in the following approximate sequence.
require.min.js overdrive.js jquery.min.js lodash.min.js cookies.min.js json3.min.js moment.min.js jquery-ui.min.js jquery-ui.min.css
E. Development Cycle
During development, you will cycle between compiling source files, deploying unminified files, and testing.
Edit a file. It will be compiled automatically via the background process.
Deploy unminified files in app directory to the test server. (A convenient way is to upload the files to /var/tmp/od/ and to symbolically link each file to the target directory, /srv/openils/var/web/js/ui/default/opac.)
On servername.domainname machine, repeat for each js files: