gmostert / ng2-breadcrumb

This is an angular 2 component that creates a breadcrumb trail. It hooks into the angular2/router, to dynamically build up the crumb trail once a component is routed to.
MIT License
102 stars 80 forks source link

Doesn't work? #4

Closed pgorbas closed 8 years ago

pgorbas commented 8 years ago

When I added this to my project by following your instructions, and try to run it I get errors. "angular2-polyfills.js:127 GET http://localhost:2512/ng2-breadcrumb/ng2-breadcrumb.js 404 (Not Found)"

I suspect the issue is the last step of your instructions which reads "To compile the project locally just run the default gulp task:" - but you don't supply a gulp file and I have no Idea what you have defined in your default task. My gulp file does not have a default task definded and I can't create it because I don't know what you want it to do.

gmostert commented 8 years ago

Dude, I guarantee you there's a gulp file. Heres a link to the it in the remote repo: https://github.com/gmostert/ng2-breadcrumb/blob/master/gulpfile.js Checkout the project again, something went wrong..

pgorbas commented 8 years ago

I must have been working about 8 hours trying to get this to run locally - either in my existing application, or in a stand alone sample - but I have not been able to do so. I've been trying both to run it inside an empty vs2015 project or by just starting an index.html and neither approach works.

The repository in gitHub at https://github.com/gmostert/ng2-breadcrumb I guess just creates the plugin, as it has no starting point - no index.html, no app.ts. etcetera.

I CAN run it in your plunker example, but downloading that plunker does not allow me to run it locally. Even running the "npm install ng2-breadcrumb --save" at the root of the plunker download didn't help.

I tried building it locally by downloading the gitHub code, and running "npm install" at the root, but when I try to run gulp I get this error:
`C:\zzWork\zPlayGround\ng2-breadcrumb-master>gulp module.js:341 throw err; ^

Error: Cannot find module 'tslint' at Function.Module._resolveFilename (module.js:339:15) at Function.Module._load (module.js:290:25) at Module.require (module.js:367:17) at require (internal/module.js:16:19) at Object. (C:\zzWork\zPlayGround\ng2-breadcrumb-master\node_modules\gulp-tslint\index.js:5:14) at Module._compile (module.js:413:34) at Object.Module._extensions..js (module.js:422:10) at Module.load (module.js:357:32) at Function.Module._load (module.js:314:12) at Module.require (module.js:367:17)`

But that's probably because just running npm install had some warnings: npm WARN gulp-tslint@4.3.5 requires a peer of tslint@^3 || >=3.1.0-dev || >=3.2.0-dev || >=3.2.1-dev || >= 3.2.2-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.7.0-dev but none was installed.

I hate to re-invent the wheel, since it looks like you already have this built, but for the life of me I can't figure out how to get it to run locally. Could you possibly post something like your plunker example inside another gitHub project that will run stand alone?

gmostert commented 8 years ago

I think my local dev env has a couple of extra things installed/configured allowing me run everything. You are right in saying that the github project serves to only dev & build the final module that can be installed for other projects.

That being said. I'm working on bringing this comp inline with the Angular 2 RC1 modules. Part of it involves changing some of the dependencies. Something like 'tsd' that has been deprecated will be removed.

The above error is due to a peer dependency of 'gulp-tslint' on 'tslint', You could try adding it to your gulpfile and see if you can compile.