خرید بک لینک

Vote count: 0

I have a JSPM/Typescript/Angular 1.5.3 project. I want to use the new component router. In my project dir, I used the command

jspm install npm:@angular/router

and it installed fine with no errors. I then added it to my app.ts file with

import ngComponentRouter from 'jspm_packages/npm/@angular/router@0.2.0/angular1/angular_1_router'

But when I start my lite-server, I get

Failed to load resource: the server responded with a status of 404 (Not Found) 
http://localhost:3000/jspm_packages/npm/@angular/instruction.json

Failed to load resource: the server responded with a status of 404 (Not Found) 
http://localhost:3000/jspm_packages/npm/@angular/utils.json

Failed to load resource: the server responded with a status of 404 (Not Found) 
http://localhost:3000/jspm_packages/npm/@angular/url_parser.json

I'm not sure why it wants to load these mysterious JSON files, so I checked my package.json:

{
  "jspm": {
    "name": "app",
    "dependencies": {
      "": "npm:@angular/router@^0.2.0",
      "angular": "npm:angular@^1.5.3", 

Hmmm...that empty "" doesn't look right. I feel like there's a build step missing if JSPM can't resolve a package name and the router is asking for JSON files. What am I doing wrong here?

asked 1 min ago

برچسب: نویسنده: استخدام کار تاريخ: دوشنبه 9 فروردين 1395 ساعت: 1:43

صفحه بندی