-
Install NodeJS
-
Install AngularCLI
npm install @angular/cli@latest -g
- Install nodemon
npm install -g nodemon
-
Download or clone this repository
-
Open the NodeJS Terminal. Run
npm install
to add the needed files into the node_modules folder
- Run
ng build
to compile the Angular front-end components into the dist
folder
- Run
node server.js
NOTE: You can also run the following command to have the Angular built and server restarted when code changes
npm start-dev
- Open localhost:3000 in your browser. You should see a basic Angular app displayed. You are now running a local server.
After doing the above:
-
Create a new project
- Name the project
- Make sure the project is selected
-
Install the Google Cloud SDK
-
Run the following command and create a new configuration. It can have any name.
gcloud init
-
Log in to your Google account
-
Select the project that you created above
-
Select the region
-
Choose a region that the server will be hosted in
-
Run the following command
gcloud app deploy
-
Wait for the app to deploy.
-
Visit the address that is displayed when the deploy command finishes.
Deployed service [default] to [https://test-project-197703.appspot.com]
npm install @angular/cli@latest -g
Note: the following was necessary to get the Angular installer to work. In future this may not be necessary.
npm install --save-dev [email protected]
ng new app-name-goes-here
cd app-name-goes-here
ng serve
Visit http:localhost:4200
npm install express body-parser --save
This project was generated with Angular CLI version 1.7.3.
Run ng serve
for a dev server. Navigate to http://localhost:4200/
. The app will automatically reload if you change any of the source files.
Run ng generate component component-name
to generate a new component. You can also use ng generate directive|pipe|service|class|guard|interface|enum|module
.
Run ng build
to build the project. The build artifacts will be stored in the dist/
directory. Use the -prod
flag for a production build.
Run ng test
to execute the unit tests via Karma.
Run ng e2e
to execute the end-to-end tests via Protractor.
To get more help on the Angular CLI use ng help
or go check out the Angular CLI README.