railinc-angular-seed
v1.0.1
Published
Railinc Angular Seed Project: (Router, Http, Forms, Services, Tests, E2E, Coverage), Karma, Protractor, Jasmine, TypeScript
Downloads
5
Maintainers
Readme
Railinc Angular Seed Project
The Official Railinc Angular 4 Seed Project.
Clone this repo and follow the steps below to get started with Angular 4 Web Application Development.
Getting Started
Assumptions / Prerequisites:
Angular 4 Development absolutely requires that the developer is developing on a VM
Please use the following Vagrant project if you don't already use a preferred setup: http://gitgogs.railinc.com:3000/railinc-developer/railinc-dev-workstation
If you are using a different VM setup, the following items are recommended:
- Using Visual Studio Code as your IDE
- Installing NVM to manage your NodeJs versions
- Using NodeJs 6.11.3 LTS
Setup Steps:
- Until this project is integrated into the Railinc Application Archetype, you must first clone this repo in the UI-Build module of the archetype. Remove all previously existing files. This repo does include a pom.xml file, which is based on Commercial RailSight projects. You'll need to modify it to fit your project.
> git clone http://gitgogs.railinc.com:3000/railinc-ui/railinc-angular-seed.git
Modify the output directory:
By default, the output directory is setup to create a target folder in the UI-Build maven module, however, this setup is specific to Commercial Railsight projects. If this is not a commercial project, you'll need to change this to put the final bundled assets into the integration module when the UI-Build module is run. To do this you'll need to modify the webpack.prod.js file, found at:
web/
├──config/ * our configuration
| ├──webpack.prod.js * Production Webpack Configuration File
- Change this line:
path: helpers.root('..', 'target', 'classes', 'META-INF', 'resources' )
- to:
path: helpers.root('..', '..', 'integration', 'src', 'main', 'webapp' )
- Please note that "integration" is referring to whatever the folder name is of your integration module. It may not be "integration".
Download Project Dependencies:
Open Visual Studio Code and open the "web" folder of the cloned project:
- File > Open Folder... > Select the "web" folder of your project
Open the built-in Terminal in Visual Studio Code:
- [CTRL + ~]
Run the initial install of the required node modules, defined in the package.json file. This may take a couple minutes
> npm i
Starting the Application:
- Now that all the dependencies have been downloaded and live in the "node_modules" directory, the application can be started.
> npm start
- This will start the web application, which can be accessed at http://localhost:3000
Things to ignore (not commit):
- node_modules/
- compiled/
- dll/