generator-angular2-library
generator-angular2-library copied to clipboard
Playground encounters 404 errors for rxjs
Hi,
I need some helps here to get my library project running using the playground. Appreciate any pieces of advice.
I can successfully compile the library to dist folder.
When I run npm lite
, I get this error in browser console window:
There is also an 404 error in the
lite-server
:
Below is my systemjs.config.js
:
'use strict';
/**
* System configuration for Angular samples
* Adjust as necessary for your application needs.
*/
(function () {
System.config({
paths: {
// paths serve as alias
'npm:': '../node_modules/'
},
// map tells the System loader where to look for things
map: {
// our app is within the app folder
app: 'app',
// angular bundles
'@angular/core': 'npm:@angular/core/bundles/core.umd.js',
'@angular/common': 'npm:@angular/common/bundles/common.umd.js',
'@angular/compiler': 'npm:@angular/compiler/bundles/compiler.umd.js',
'@angular/platform-browser': 'npm:@angular/platform-browser/bundles/platform-browser.umd.js',
'@angular/platform-browser-dynamic': 'npm:@angular/platform-browser-dynamic/bundles/platform-browser-dynamic.umd.js',
'@angular/http': 'npm:@angular/http/bundles/http.umd.js',
'@angular/router': 'npm:@angular/router/bundles/router.umd.js',
'@angular/forms': 'npm:@angular/forms/bundles/forms.umd.js',
// other libraries
rxjs: 'npm:rxjs',
'angular-in-memory-web-api': 'npm:angular-in-memory-web-api/bundles/in-memory-web-api.umd.js',
'ng-lib-test': '../dist'
},
// packages tells the System loader how to load when no filename and/or no extension
packages: {
app: {
defaultExtension: 'js',
meta: {
'./*.js': {
loader: 'systemjs-angular-loader.js'
}
}
},
rxjs: {
defaultExtension: 'js'
},
'ng-lib-test': {
main: 'ng-lib-test.umd.js',
defaultExtension: 'js'
}
}
});
})(this);
Related: https://github.com/jvandemo/generator-angular2-library/issues/255
@caroso1222 — Thank you for your follow-up.
@izifortune — Would you be able to have a look a this?
Thanks in advance!
Same here:
Any updates?
Hi @sheldonyss do you have the same problem running npm run playground
? Because npm run lite
its meant to be runned only inside the other command not as a standalone
Same here
Same here. I got 404 at fetch.js at first, then i deleted .playground and got 404 at system.src.js