Questions tagged [angular2-cli]

124 questions
3
votes
1 answer

How can I use a window object in Angular 2?

I tried to put the following code to get a window object in angular 2: @Component({ selector: 'app-slider', templateUrl: './slider.component.html', styleUrls: ['./slider.component.css'], providers: [ …
Martin
  • 33
  • 1
  • 1
  • 5
3
votes
2 answers

How to use Susy in Angular 2 CLI

Overview I love the new Angular 2 CLI, I was able to migrate my old front structure into it just fine. I however, have had trouble getting Susy (http://susy.oddbird.net/) to load. It is a gem that is installed and can be used as a mixin. I thought…
Bromox
  • 567
  • 2
  • 9
  • 29
3
votes
2 answers

Angular 2 CLI so much time compiling

I'm working in a pretty big project and using Angular 2 with Angular 2 CLI beta 21. I am currently amazed about big compilation times and updating times. Here you have an ng serve output. It's 44.8s. $:ng serve ** NG Live Development Server is…
vpedrosa
  • 811
  • 1
  • 6
  • 17
3
votes
0 answers

cannot require files with dynamic path anymore

We used to be able to to do this : let path = 'test.component.ts'; let file = require('./path/to/file/'+path); console.log('file',file); But this is not working any more with the latest cli. This works : let file =…
Milad
  • 27,506
  • 11
  • 76
  • 85
3
votes
1 answer

Unknown compiler option 'angularCompilerOptions' in angular 2 ahead-of-time compilation

I'm trying to use AOT compiler in this angular 2 project. I get error: TypeError: this.compiler.compileModules is not a function when I execute command: "node_modules/.bin/ngc" -p tsconfig-aot.json . How to solve this issue? Steps to…
Ildar
  • 3,808
  • 7
  • 45
  • 81
3
votes
2 answers

Angular CLI installation failure

Installing Angular CLI (angular-cli@1.0.0-beta.16) via npm install -g angular-cli@latest failed with the following error in npm-debug.log: Error: The package webpack@2.1.0-beta.22 does not satisfy its siblings' peerDependencies requirements! at…
Jan Nielsen
  • 10,892
  • 14
  • 65
  • 119
3
votes
2 answers

Angular 2 RC6: cli-compiler says "function calls are not supported"

When trying to compile my RC6 app using the following command: ngc -p C:\Path\To\Project (I am placed inside C:\Path\To\Project\node_modules\.bin when I'm running the command) I get the following error: Error encountered resolving symbol values…
Glenn Utter
  • 2,313
  • 7
  • 32
  • 44
3
votes
1 answer

Angular cli npm start failed

I'm using angular-cli for my first angular 2 project, but it generates the error below when I use npm start command Running without elevated rights. Running Ember CLI "as Administrator" increases performance significantly. See…
Radonirina Maminiaina
  • 6,958
  • 4
  • 33
  • 60
3
votes
1 answer

What is the task of the 'cliSystemConfigPackages' object in the angular 2 CLI configuration

I am using angular 2 and the CLI. As there exist no information on https://github.com/angular/angular-cli about the meaning of the barrels in combination with the angular 2 CLI tool I ask here... My angular 2 app works ok so far that means I get no…
Elisabeth
  • 20,496
  • 52
  • 200
  • 321
3
votes
2 answers

Angular2 CLI working

After the Release of angular CLI, I have decided to work with angular CLI but from very start leads to some confusion which are not cleared yet so hope somewhere here help me out :- In index.html i have found some amazing interpolation syntax of…
Pardeep Jain
  • 84,110
  • 37
  • 165
  • 215
2
votes
1 answer

Property 'withServerTransition' does not exist on type 'typeof BrowserModule'.)

Am Using the angular universal 1.0.0-alpha.universal.3 I have created the new app using the angular universal cli. ung new test-app --universal package.json { "name": "test-app", "version": "0.0.0", "license": "MIT", "angular-cli": {}, …
2
votes
2 answers

'webpack-dev-server' is not recognized as an internal or external command, operable program or batch file?

E:\MyProjects\MyMLM\Layer1.UI>npm start mymlm@1.0.0 start E:\MyProjects\MyMLM\Layer1.UI webpack-dev-server --no-inline --progress --port 9090 'webpack-dev-server' is not recognized as an internal or external command, operable program or batch…
parvat
  • 161
  • 1
  • 2
  • 6
2
votes
0 answers

What's the difference between NgcLoader and awesome-typescript-loader?

I'm reading this article about @ngtools/webpack NgcLoader and it has the following code: if (envOptions.MODE === 'prod') { config.module.rules.push( { test: /\.ts$/, loaders: ['@ngtools/webpack'] } ); ... } else { …
Max Koretskyi
  • 101,079
  • 60
  • 333
  • 488
2
votes
1 answer

RxJs operators causing typescript errors

Working version: const observable = Observable .from([Promise.resolve('1'), Promise.resolve('2')]) .subscribe((results) => {}) Broken version (added mergeAll operator): const observable = Observable .from([Promise.resolve('1'),…
manidos
  • 3,244
  • 4
  • 29
  • 65
2
votes
3 answers

How to use handsontable library in angular 2

I am new to configuration part in npm, i am trying to use handsontable library in angular 2 project created using angular-cli (ng init). I added the typescript definition for the same. Here is my app.compponent.ts import { Component } from…
1 2
3
8 9