date-time-picker
date-time-picker copied to clipboard
Extend peer dependencies to Angular 8
Issue description
running npm install
throws the following warning:
npm WARN [email protected] requires a peer of @angular/cdk@^7.0.0 but none is installed. You must install peer dependencies yourself.
Steps to reproduce and a minimal demo of the problem
npm install
with Angular 8
Current behavior
npm install
shows a couple of warning due to peer dependencies.
Expected/desired behavior
No warnings should be shown
+1
+1
also cannot compile using Ivy...
WARNING in Entry point 'ng-pick-datetime-moment' contains deep imports into 'moment/moment'. This is probably not a problem, but may cause the compilation of entry points to be out of order.
ERROR in src/app/app.module.ts(496,11): error TS-991010: Value at position 4 in the NgModule.importss of AppModule is not a reference: [object Object]
not compiling with ng8 IVY
error: ERROR in ./src/app/shared/shared.module.ts 101:12-29 "export 'OwlDateTimeModule' was not found in 'ng-pick-datetime' ERROR in ./src/app/shared/shared.module.ts 184:12-29 "export 'OwlDateTimeModule' was not found in 'ng-pick-datetime' ERROR in ./src/app/shared/shared.module.ts 102:12-35 "export 'OwlNativeDateTimeModule' was not found in 'ng-pick-datetime' ERROR in ./src/app/shared/shared.module.ts 185:12-35 "export 'OwlNativeDateTimeModule' was not found in 'ng-pick-datetime' ERROR in ./node_modules/ng-pick-datetime/ivy_ngcc/picker.jsERROR in ./node_modules/ng-pick-datetime/ivy_ngcc/picker.js Module not found: Error: Can't resolve './date-time' in './node_modules/ng-pick-datetime/ivy_ngcc' ERROR in ./node_modules/angular-checklist/ivy_ngcc/dist/index.js Module not found: Error: Can't resolve './directives/checklist.directive' in './node_modules/angular-checklist/ivy_ngcc/dist'
+1
+1
I really like this plugin and appreciate the work that has been done. However, looking at Daniel's activity, PRs left untouched and the increasing # of issues with each of angular's updates I am really questioning whether I can afford to include this in projects.
I really like this plugin and appreciate the work that has been done. However, looking at Daniel's activity, PRs left untouched and the increasing # of issues with each of angular's updates I am really questioning whether I can afford to include this in projects.
If you found another date time picker, please free to comment here to evaluate migrating our code please!
Best regards
I really like this plugin and appreciate the work that has been done. However, looking at Daniel's activity, PRs left untouched and the increasing # of issues with each of angular's updates I am really questioning whether I can afford to include this in projects.
If you found another date time picker, please free to comment here to evaluate migrating our code please!
Best regards https://github.com/kekeh/angular-mydatepicker I am going to test it.
@busacca currently has a version published on npm with updated dependencies. Code checks out, instilling it now to see if I run into problems on my project. You can install your version your self using npm install @busacca/ng-pick-datetime
.
I'll switch back once @DanielYKPan updates this project. Great library, would be a shame if it stops here.
@busacca currently has a version published on npm with updated dependencies. Code checks out, instilling it now to see if I run into problems on my project. You can install your version your self using
npm install @busacca/ng-pick-datetime
.I'll switch back once @DanielYKPan updates this project. Great library, would be a shame if it stops here.
I tried to use the @busacca version, but got problems when angular run the migration... migrated configurations manually and got this error, when try to compile to production
ERROR in ../ng-pick-datetime-moment/moment-adapter/moment-date-time.module.ts(22,2): Error during template compile of 'OwlMomentDateTimeModule'
Function calls are not supported in decorators but 'ɵmakeDecorator' was called in 'NgModule'
'NgModule' calls 'ɵmakeDecorator'.
Maybe it's because in my version the OwlMomentDateTimeModule is part of @busacca/ng-pick-datetime
instead of and external package?
Your're using the following import?
import { OwlDateTimeModule, OwlMomentDateTimeModule } from '@busacca/ng-pick-datetime';
Maybe it's because in my version the OwlMomentDateTimeModule is part of
@busacca/ng-pick-datetime
instead of and external package?Your're using the following import?
import { OwlDateTimeModule, OwlMomentDateTimeModule } from '@busacca/ng-pick-datetime';
I was using it from @busacca, but I left the OwlMomentDateTimeModule import { OwlMomentDateTimeModule } from 'ng-pick-datetime-moment';
I already migrated the pick calendar to another library, and cannot test if this works :( I will do a test in a few hours, only to check. Thanks for your response.
Maybe it's because in my version the OwlMomentDateTimeModule is part of
@busacca/ng-pick-datetime
instead of and external package?Your're using the following import?
import { OwlDateTimeModule, OwlMomentDateTimeModule } from '@busacca/ng-pick-datetime';
For anyone interested in using this picker move to @dbusacca version, And import OwlMomentDateTimeModule from '@busacca/ng-pick-datetime'; instead of @DanielYKPan package.
All works like a charm.
I get following error when I use @dbusacca 's version:
ERROR in ./node_modules/@busacca/ng-pick-datetime/date-time/adapter/moment-adapter/moment-date-time-adapter.class.js Module not found: Error: Can't resolve 'moment/moment' in 'C:\Users\some\path\node_modules\@busacca\n g-pick-datetime\date-time\adapter\moment-adapter'
How can I fix this?
@dbusacca Sir, can you also include OWL_MOMENT_DATE_TIME_ADAPTER_OPTIONS
that were in ng-pick-datetime-moment
package in your package as well? Would be super grateful, sir!
@dbusacca Sir, can you also include
OWL_MOMENT_DATE_TIME_ADAPTER_OPTIONS
that were inng-pick-datetime-moment
package in your package as well? Would be super grateful, sir!
I've published a new revision 8.0.2
which exports OWL_MOMENT_DATE_TIME_ADAPTER_OPTIONS
and MomentDateTimeAdapter
I get following error when I use @dbusacca 's version:
ERROR in ./node_modules/@busacca/ng-pick-datetime/date-time/adapter/moment-adapter/moment-date-time-adapter.class.js Module not found: Error: Can't resolve 'moment/moment' in 'C:\Users\some\path\node_modules\@busacca\n g-pick-datetime\date-time\adapter\moment-adapter'
How can I fix this?
@IslombekMe have you added the peer dependencies moment
and @types/moment
to the project?
@dbusacca Thank you for updating this project. Any chance you could open up issues on your fork as this repo hasn't been touched in quite some time?
And if anyone runs into the following error with Angular 8
TypeError: Class constructor BasePortalOutlet cannot be invoked without 'new'
You can change your tsconfig.json compileOptions from: "module": "esnext", "target": "es2015", to: "module": "es2015", "target": "es5",
I get following error when I use @dbusacca 's version:
ERROR in ./node_modules/@busacca/ng-pick-datetime/date-time/adapter/moment-adapter/moment-date-time-adapter.class.js Module not found: Error: Can't resolve 'moment/moment' in 'C:\Users\some\path\node_modules\@busacca\n g-pick-datetime\date-time\adapter\moment-adapter'
How can I fix this?
did u get a fix for this (angular 8 update)?