Saturday, February 27, 2016

Building Angular 2 beta.7 on windows 10

It just quick note and some time saving for new of us in nodes js\grunt and angular 2 overall.
Here i have some hints for gulp build task.

Once you cloned  repo from here: https://github.com/angular/angular
you need to check you have right version of node server and npm.

Node.js, (version >=5.4.1 <6) which is used to run a development web server, run tests, and generate distributable files. We also use Node's Package Manager, npm (version >=3.5.3 <4.0), which comes with Node. Depending on your system, you can install Node either from source or as a pre-packaged bundle.

from  dev readme in master.

The steps you need besides run npm install in root:


  1.   install bower dependency
             Run bower install  from root
             If you ll see error like this
              bower angular#1.0.6 ENOGIT git is not installed or not in the PATH then you need to specify environment variable Path like this:

set PATH=%PATH%;C:\Program Files\Git\bin

              replace path with your folder's path to git.exe.



      2.   From your local repo go to folder   angular\tools  and run these commands from there:
            in order to install tool's dependencies,
npm install
tsd install

             Without this commands you should see error like this:
                error TS2304: Cannot find name 'promise'
                or
                error TS2304: Cannot find name 'require'
             or whatever it looking for.


    3. From local repo root go to folder angular\modules\angular2 and run the same command from step 2.

npm install
tsd install

    Without running this command have errors like that:
         Error: [DiffingTSCompiler]: Typescript found the following errors:
           angular2/manual_typings/globals.d.ts (8, 42): Cannot find name 'Promise'.









         



       







No comments:

Post a Comment