Version 2.0.0.rc.0 bug with angular 9
vm2geo opened this issue · comments
vm2geo commented
I'm trying to use this library with angular 9 but it's occurring bugs related to entry components like this simple example https://stackblitz.com/edit/angular-mcs7ll
Error: No component factory found for MatPaginator. Did you add it to @NgModule.entryComponents?
And with my project that is using Angular 8 with nGrid 1 it's working perfectly, but when i try to upgrade many bugs happened
ERROR in node_modules/@pebula/ngrid/drag/lib/drag-and-drop/column/aggregation-column.d.ts:7:22 - error TS2720: Class 'PblNgridAggregationContainerDirective<T>' incorrectly implements class 'CdkLazyDropList<T, any>'. Did you mean to extend 'CdkLazyDropList<T, any>' and inherit its members as a subclass?
Property '_draggables' is missing in type 'PblNgridAggregationContainerDirective<T>' but required in type 'CdkLazyDropList<T, any>'.
7 export declare class PblNgridAggregationContainerDirective<T = any> extends CdkDropList<T> implements OnDestroy, CdkLazyDropList<T> {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/core/lazy-drag-drop.d.ts:14:5
14 _draggables: QueryList<CdkDrag>;
~~~~~~~~~~~
'_draggables' is declared here.
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/column/column-reorder-plugin.d.ts:15:22 - error TS2720: Class 'PblNgridColumnReorderPluginDirective<T>' incorrectly implements class 'CdkLazyDropList<T, PblNgridColumnReorderPluginDirective<T>>'. Did you mean to extend 'CdkLazyDropList<T, PblNgridColumnReorderPluginDirective<T>>' and inherit its members as a subclass?
Property '_draggables' is missing in type 'PblNgridColumnReorderPluginDirective<T>' but required in type 'CdkLazyDropList<T, PblNgridColumnReorderPluginDirective<T>>'.
15 export declare class PblNgridColumnReorderPluginDirective<T = any> extends CdkDropList<T> implements OnInit, OnDestroy, CdkLazyDropList<T, PblNgridColumnReorderPluginDirective<T>> {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/core/lazy-drag-drop.d.ts:14:5
14 _draggables: QueryList<CdkDrag>;
~~~~~~~~~~~
'_draggables' is declared here.
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/column/column-reorder-plugin.d.ts:54:119 - error TS2344: Type 'PblNgridColumnReorderPluginDirective<T>' does not satisfy the constraint 'CdkLazyDropList<T, any>'.
Property '_draggables' is missing in type 'PblNgridColumnReorderPluginDirective<T>' but required in type 'CdkLazyDropList<T, any>'.
54 export declare class PblNgridColumnDragDirective<T = any> extends CdkDrag<T> implements AfterViewInit, CdkLazyDrag<T, PblNgridColumnReorderPluginDirective<T>, PblNgridColumnDragDirective<T>> {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/core/lazy-drag-drop.d.ts:14:5
14 _draggables: QueryList<CdkDrag>;
~~~~~~~~~~~
'_draggables' is declared here.
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/row/row-reorder-plugin.d.ts:13:22 - error TS2720: Class 'PblNgridRowReorderPluginDirective<T>' incorrectly implements class 'CdkLazyDropList<T, PblNgridRowReorderPluginDirective<T>>'. Did you mean to extend 'CdkLazyDropList<T, PblNgridRowReorderPluginDirective<T>>' and inherit its members as a subclass?
Property '_draggables' is missing in type 'PblNgridRowReorderPluginDirective<T>' but required in type 'CdkLazyDropList<T, PblNgridRowReorderPluginDirective<T>>'.
13 export declare class PblNgridRowReorderPluginDirective<T = any> extends CdkDropList<T> implements OnDestroy, CdkLazyDropList<T, PblNgridRowReorderPluginDirective<T>> {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/core/lazy-drag-drop.d.ts:14:5
14 _draggables: QueryList<CdkDrag>;
~~~~~~~~~~~
'_draggables' is declared here.
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/row/row-reorder-plugin.d.ts:37:101 - error TS2344: Type 'PblNgridRowReorderPluginDirective<T>' does not satisfy the constraint 'CdkLazyDropList<T, any>'.
Property '_draggables' is missing in type 'PblNgridRowReorderPluginDirective<T>' but required in type 'CdkLazyDropList<T, any>'.
37 export declare class PblNgridRowDragDirective<T = any> extends CdkDrag<T> implements CdkLazyDrag<T, PblNgridRowReorderPluginDirective<T>> {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
node_modules/@pebula/ngrid/drag/lib/drag-and-drop/core/lazy-drag-drop.d.ts:14:5
14 _draggables: QueryList<CdkDrag>;
~~~~~~~~~~~
'_draggables' is declared here.
Then when i change ... CdkDropList<T> ...
to ... CdkLazyDropList<T> ...
my project worked but when using ng serve the entry components bug happen
ERROR Error: Uncaught (in promise): Error: No component factory found for DragPluginDefaultTemplatesComponent. Did you add it to @NgModule.entryComponents?
Error: No component factory found for DragPluginDefaultTemplatesComponent. Did you add it to @NgModule.entryComponents?
at noComponentFactoryError (core.js:27414)
at CodegenComponentFactoryResolver.resolveComponentFactory (core.js:27490)
at CodegenComponentFactoryResolver.resolveComponentFactory (core.js:27487)
at Function.loadCommonTemplates (pebula-ngrid.js:14430)
at new PblNgridModule (pebula-ngrid.js:14383)
at _createClass (core.js:32044)
at _createProviderInstance (core.js:32005)
at initNgModule (core.js:31909)
at new NgModuleRef_ (core.js:32926)
at createNgModuleRef (core.js:32909)
at resolvePromise (zone-evergreen.js:793)
at resolvePromise (zone-evergreen.js:752)
at zone-evergreen.js:854
at ZoneDelegate.invokeTask (zone-evergreen.js:400)
at Object.onInvokeTask (core.js:41244)
at ZoneDelegate.invokeTask (zone-evergreen.js:399)
at Zone.runTask (zone-evergreen.js:168)
at drainMicroTaskQueue (zone-evergreen.js:570)
Can you help me spot the issue? I really like your library. Thanks
Shlomi Assaf commented
Shlomi Assaf commented
Version 2.0.0-rc.1 should fix both issues.