JavaScript – Learning notes – part 1

Values:

  • Data types
  • Numbers, strings, boolean, objects, functions, undefined values

  1.  Numbers: numeric values. Fixed number of bits of 64 for representation(2^64 different numbers). 3 Special numbers are infinity, -infinity, NaN( Not a Number)
  2. Strings: represented with single or double quotes. \ is used for escaping character.
  3. Boolean: true or false
  4. Undefined values: null and undefined.

    Operators:

    1. Arithmetic operators: +,-,/,*,%
    2. Unary operators: typeof, !
    3. Logical operators: &&, ||
    4.  Conditional operators: ?:(ternary operator)

    Type Conversion:

    * When an operator is applied to the wrong type of value, JS will convert that value to the type it wants( Type Coercion ) 

    Eg: 8*null -> 0

            “5” – 1  -> 4

            

    java 8 installation

    $ sudo add-apt-repository ppa:webupd8team/java
    $ sudo apt-get update
    $ sudo apt-get install oracle-java8-installer
    
    java -version
    
    java version "1.8.0_91"
    Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
    Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)
    
    
    sudo apt-get install oracle-java8-set-default

    Web development testing tools and sites

    I came across this recently while studying the web development courses.

    This helps in faster testing of your code by synchronizing file changes and creates a temporary server.

    Installation:

    npm install -g browser-sync

    Start Browser sync
    In your project folder
    
    browser-sync start --server --directory --files "*"
    
    Note
    Below sites will also be helpful for testing:
    https://jsfiddle.net/
    http://codepen.io/#
    https://css-tricks.com/
    
    Site to check Standards and compatibility:
    http://caniuse.com/
    http://validator.w3.org/
    http://www.w3schools.com/browsers/browsers_stats.asp
    
    Important links:
    https://www.w3.org/TR/html5/dom.html
    
    To test the network issues or delays:
    ctrl + shift + i - chrome development tools
    network tab -  A throttling setting , Change setting 
    
    Web designing mockup:
    https://www.invisionapp.com/
    https://marvelapp.com/
    https://balsamiq.com/ (not free)
    
    Fonts:
    google.com/fonts
    
    
    
    

     

    Sublime Text installation

    For Sublime-Text-2:

    sudo add-apt-repository ppa:webupd8team/sublime-text-2
    sudo apt-get update
    sudo apt-get install sublime-text
    

    For Sublime-Text-3:

    sudo add-apt-repository ppa:webupd8team/sublime-text-3
    sudo apt-get update
    sudo apt-get install sublime-text-installer