New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using angular2-calendar with webpack #85
Comments
Turns out, that this solution works. But maybe someone would like to read these steps. Issue can be closed |
I think your issue was caused by webpack trying to transpile the library in node_modules which shouldn't be done as it's already transpiled: https://github.com/qdouble/angular-webpack2-starter/blob/master/webpack.config.ts#L132 |
I'm still having this issue Cannot find source file '../src/calendar-utils.ts': Error: Can't resolve '../src/calendar-utils.ts' any tips? |
It sounds like your webpack config is trying to transpile your node_modules folder, make sure you have |
@SebastianPodgajny I had the same errors, I figured this out, just add these packages to your package.json file . I don't think it is mentioned in the library though "dependencies": { then, |
Hi,
I don't get the angular2-calendar running with webpack.
I am using this starter: https://github.com/qdouble/angular-webpack2-starter
Npm throws this error, when building the app:
WARNING in ./~/angular2-calendar/~/calendar-utils/dist/src/calendarUtils.js Cannot find source file '../../src/calendarUtils.ts': Error: Can't resolve '../../src/calendarUtils.ts' in '/Users/Flo/projects/angular2-webrtc/node_modules/angular2-calendar/node_modules/calendar-utils/dist/src' @ ./~/angular2-calendar/dist/esm/src/components/week/calendarWeekView.component.js 2:0-64 @ ./~/angular2-calendar/dist/esm/src/index.js @ ./src/app/app.imports.ts @ ./src/app/app.module.ts @ ./src/main.browser.ts @ multi main
What I did:
Installed angular2-calendar:
npm install angular2-calendar --save
Copy required css to dist via COPY_FOLDERS:
{ from: 'node_modules/angular2-calendar/dist/css/angular2-calendar.css' },
and added this to index.html:
<link rel="stylesheet" href="angular2-calendar.css">
Import Module:
CalendarModule.forRoot()
I don't see why it does not work? Any advise?
The text was updated successfully, but these errors were encountered: