Code Monkey home page Code Monkey logo

gistutorials-web's Introduction

Angular installation

Tutorial

On Youtube

Commands

  1. Install npm: $ sudo pacman -S npm
  2. Change npm default directory (permissions issue):
$ mkdir ~/.node_modules
$ npm config set prefix ~/.node_modules
$ echo 'export PATH=~/.node_modules/bin:PATH' >>  ~/.bashrc
$ source ~/.bashrc
$ ng
  1. Install angular-cli: npm install -g @angular/cli
  2. Install rxjs: npm install -g rxjs
  3. Create a new project: ng new <project-name>
  4. Run the server: ng serve
  5. Create a new component: ng generate component <component-name>
  6. Create a new service: ng generate service <service-name>
  7. Install angular-material (User Interface): npm install @angular/material @angular/cdk @angular/animations
  8. Install angulatics2 (Google Analytics): npm install angulartics2
  9. Install flex-layout (Responsiveness): npm install @angular/flex-layout
  10. Install ngx-sharebuttons (Share on social media): npm install @ngx-share/core @ngx-share/button font-awesome
  11. Install ngx-highlightjs (Code syntax highlighting): npm install ngx-highlightjs
  12. Install ngx-page-scroll (Scroll to content): npm install ngx-page-scroll
  13. Install ngx-disqus (Disqus comments): npm install ngx-disqus

Installation of this repo

Just replace the /src folder using the content of this repo

Deploy app to server

$ ng build --prod --deploy-url=/

And a dist folder will be created at the root of the project, where its static files will be served from /expenses.

Using SCSS instead of CSS

SCSS is more suitable to customize the themes of Material than CSS. According to this tutorial, to switch to SCSS:

$ ng set defaults.styleExt scss

If you get an error related to Node-sass, the following command might fix it:

$ npm rebuild node-sass

Afterwards you need to reference the correct styles file in .angular-cli.json:

"styles": [
  "sass/styles.scss"
],

gistutorials-web's People

Contributors

h4k1m0u avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.