Skip to content

How to use r.js to build a project that includes Lightstreamer JS client library

Notifications You must be signed in to change notification settings

mone/lightstreamer-example-js-client-project

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

Lightstreamer :: Example Project

This example shows how a project using the Lightstreamer JS client can be built using the r.js optimizer.

The project uses RequireJS as AMD loader, its domReady! plugin, the Lightstreamer JS Client 6 library and a custom MySubscriber module.

Build

You can build the project using either Rhino (and optionally Google Closure Compiler) or Node.js. The built files will appear in the deploy folder.

A full guide to optimization is available in the RequireJS website The full list of options for the configuration file is available on r.js github repo

Using Rhino

  1. Install java on the machine.

  2. from the build folder run

     java -cp compiler.jar;js.jar org.mozilla.javascript.tools.shell.Main r.js -o app.build.js
    

Using Node.js

  1. Install node on the machine.

  2. modify the build/app.build.js file removing the optimize property.

  3. from the build folder run

     node r.js -o app.build.js
    

Resources

This project contains several different external resources you may want to upgrade before using using in your own project:

  1. build/compiler.jar from Google Closure Compiler
  2. build/js.jar from Rhino
  3. build/r.js from r.js
  4. src/js/require.js from RequireJS
  5. src/js/domReady.js from domReady
  6. src/js/lightstreamer_namespace.js from Lightstreamer

About

How to use r.js to build a project that includes Lightstreamer JS client library

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published