Open weishiny opened 7 years ago
I am not sure latest version is compatible with SystemJS, I would need to check it.
Can you try version prior to https://github.com/jkuri/ng2-datepicker/commit/639e9ce8deeb5260ffa67ad21e24269ac60f5613 please. 1.8.0
I think.
Hi @jkuri ,
I've tried the version 1.8.0 and it's work for systemJS, thanks, but I encounter another problem that is
Error: Uncaught (in promise): Failed to load ng2-datepicker.component.html at resolvePromise (http://localhost:3000/node_modules/zone.js/dist/zone.js:665:31) [<root>] at resolvePromise (http://localhost:3000/node_modules/zone.js/dist/zone.js:636:17) [<root>] at http://localhost:3000/node_modules/zone.js/dist/zone.js:713:17 [<root>] at Zone.runTask (http://localhost:3000/node_modules/zone.js/dist/zone.js:166:47) [<root> => <root>] at drainMicroTaskQueue (http://localhost:3000/node_modules/zone.js/dist/zone.js:546:35) [<root>] at XMLHttpRequest.ZoneTask.invoke (http://localhost:3000/node_modules/zone.js/dist/zone.js:424:25) [<root>]
and i've read the post #66
but i 'm sorry that I don't clearly understand what the solution is. Could you provide a clearer direction for me, I appreciate you for your reply. sorry for my poor english. :_
@weishiny I think moduleId: module.id
was needed in component for SystemJS to find the template. Can you try with Angular 4.0.0, I believe this is not needed anymore.
Hi @jkuri, do you mean your ng2-datepicker.component.ts inside node_module should be added for moduleId: module.id? If so, can I just add moduleId: module.id into ng2-datepicker.component.ts in the first place? If it is not working and then I will try using angular4
Guys, I am using TypeScript 2.5 and just downloaded ng2-datepicker 2.1.3.
Although I followed the instructions, however I get the same error. any help is really appreciated. Using System.Config.JS.
I have tried other versions like 1.8.2 and none of them are working.
(SystemJS) XHR error (404 Not Found) loading http://localhost:44331/node_modules//ng2-datepicker/ng2-datepicker.js
I'm receiving a similar error as @therisenlord . Please advise as to how to resolve.
Error loading http://localhost:3000/node_modules/ng2-datepicker/src/main.ts as "ng2-datepicker"
Hi,
@jkuri I followed your readme.md guide but I found I still encounter the problem about the following:
Error: (SystemJS) XHR error (404 Not Found) loading http://localhost:3000/node_modules/ng2-datepicker/ng2-datepicker.js Error: XHR error (404 Not Found) loading http://localhost:3000/node_modules/ng2-datepicker/ng2-datepicker.js at XMLHttpRequest.wrapFn [as __zone_symbol___onreadystatechange] (http://localhost:3000/node_modules/zone.js/dist/zone.js:1242:29) [<root>] at Zone.runTask (http://localhost:3000/node_modules/zone.js/dist/zone.js:166:47) [<root> => <root>] at XMLHttpRequest.ZoneTask.invoke (http://localhost:3000/node_modules/zone.js/dist/zone.js:420:38) [<root>] Error loading http://localhost:3000/node_modules/ng2-datepicker/ng2-datepicker.js as "ng2-datepicker" from http://localhost:3000/app/app.module.js at XMLHttpRequest.wrapFn [as __zone_symbol___onreadystatechange] (http://localhost:3000/node_modules/zone.js/dist/zone.js:1242:29) [<root>] at Zone.runTask (http://localhost:3000/node_modules/zone.js/dist/zone.js:166:47) [<root> => <root>] at XMLHttpRequest.ZoneTask.invoke (http://localhost:3000/node_modules/zone.js/dist/zone.js:420:38) [<root>] Error loading http://localhost:3000/node_modules/ng2-datepicker/ng2-datepicker.js as "ng2-datepicker" from http://localhost:3000/app/app.module.js at addToError (http://localhost:3000/node_modules/systemjs/dist/system.src.js:122:78) [<root>] at linkSetFailed (http://localhost:3000/node_modules/systemjs/dist/system.src.js:695:21) [<root>] at http://localhost:3000/node_modules/systemjs/dist/system.src.js:495:9 [<root>] at Zone.run (http://localhost:3000/node_modules/zone.js/dist/zone.js:126:43) [<root> => <root>] at http://localhost:3000/node_modules/zone.js/dist/zone.js:713:57 [<root>] at Zone.runTask (http://localhost:3000/node_modules/zone.js/dist/zone.js:166:47) [<root> => <root>] at drainMicroTaskQueue (http://localhost:3000/node_modules/zone.js/dist/zone.js:546:35) [<root>] at XMLHttpRequest.ZoneTask.invoke (http://localhost:3000/node_modules/zone.js/dist/zone.js:424:25) [<root>]
And the following is my system.config.js The version of ng2-datepicker is ng2-datepicker@1.8.2, and I've already tried some issues that be posted before but I still can not find solution, There's no index.js, there's no ng2-datepicker.umd.js and ng2-datepicker.js so that I have no idea how to set the configuration for system.js, I'm wondering whether the version is the cause?
#200 #133
` (function (global) { 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',
}); })(this); `