Skip to content

Latest commit

 

History

History
39 lines (29 loc) · 1.53 KB

README.md

File metadata and controls

39 lines (29 loc) · 1.53 KB

MAGE Web Application

The MAGE web client is built on AngularJS.

Building

The MAGE web client uses npm and webpack to manage dependencies and bundle assets. From the MAGE base directory, run

$ npm run build

or from the public directory

$ npm install
$ npm run build

Running MAGE web client

For the web client to be useful, you'll want to start a local MAGE server.

Debug build

From the public directory run

$ npm run start

This command uses the development webpack config to start a server running on http://localhost:3000. That configuration also proxies all requests for /api to the local MAGE server, which the configuration assumes is bound to http://localhost:4242. This debug webpack server will watch and hot-load any changes to the resources in the public directory, and apply source maps so you can inspect the content in your browser's development console.

Production build

The npm run build command you ran earlier uses the webpack production to minify, obfuscate, and bundle all of the MAGE web app's JavaScript and CSS assets into the dist directory. The MAGE server Express configuration will serve the assets from that directory. You can also potentially serve the contents of that directory from a separate reverse proxy server, such as nginx or Apache httpd, as they are just static web resources.