Crazyht / ngx-tree-select

Angular select component with tree items
https://crazyht.github.io/ngx-tree-select/
MIT License
56 stars 45 forks source link

ngx-tree-select angular 10 issue #193

Open telishreyas10 opened 4 years ago

telishreyas10 commented 4 years ago

Hello,

I have migrated my angular 9 project to angular 10. After completing all necessary migration steps, I tried to do ng serve on my project and I started to get this error:

**ERROR in node_modules/ngx-tree-select/src/module.d.ts:11:56 - error TS2314: Generic type 'ModuleWithProviders' requires 1 type argument(s).

FYI: while migration from 9 to 10 I have used --force flag along with ng update

02jaysenghani commented 4 years ago

Facing same issue after migrating project angular 9 to angular 10

AcidSlide commented 3 years ago

@Crazyht I do hope this can be fixed as your module is exactly what I need, but we have already migrated our projects to Angular 10

AcidSlide commented 3 years ago

Looks like this project is dead in the waters 😩

Nokhoneryu commented 3 years ago

Guys, i fixed the error in #204 . Basically the ModulesWithProviders now requires a type, you can do it locally, as a temporary workaround, but i need the pull request to be merged and a new build to fix it for good :\

Nokhoneryu commented 3 years ago

This issue is fixed by #204 and can now be closed

AcidSlide commented 3 years ago

This issue is fixed by #204 and can now be closed

This is so great to hear.. so we will just wait for the update via NPM.. thanks

Crazyht commented 3 years ago

I closed this issue only when build server want compile changes :P For the moment I get some error

Nokhoneryu commented 3 years ago

I've seen the error in the build, it seems that in the actual angular version of this project, ModuleWithProviders must have a generic type, and in angular 10 must have an explicit type (generally the Module to which it refers to)... I thought it was overridable in previous versions, but i was wrong... We must overhaul the project dependencies to angular 10+ in order to build properly... I'm working on that currently

AcidSlide commented 3 years ago

any updates on this? :)

Nokhoneryu commented 3 years ago

Kinda... I've been trying to bring the app to Angular 11, however, since the app hasn't been updated in a while, i'm in a peer deps hell, where quite a few don't have angular 11 compatible versions...

Sakthivelv commented 3 years ago

Hi all i have fixed this

see the updated code


export declare class NgxTreeSelectModule {
    static forRoot(options: TreeSelectDefaultOptions): ModuleWithProviders<NgxTreeSelectModule>;
    static ɵmod: ɵngcc0.ɵɵNgModuleDefWithMeta<NgxTreeSelectModule, [typeof ɵngcc1.TreeSelectComponent, typeof ɵngcc2.TreeSelectItemComponent, typeof ɵngcc3.OffClickDirective, typeof ɵngcc4.ItemPipe], [typeof ɵngcc5.CommonModule, typeof ɵngcc6.FormsModule], [typeof ɵngcc1.TreeSelectComponent]>;
    static ɵinj: ɵngcc0.ɵɵInjectorDef<NgxTreeSelectModule>;
}
mobilestar1 commented 3 years ago

When do you plan to update NPM?

LoGA80 commented 3 years ago

We are in the middle of a migration project from Angular 5 to 11 and we wish to continue using ngx-tree-select but for that we need this fix to be packaged and available through NPM. Do you have an idea when we can expect that to happen?

AcidSlide commented 3 years ago

Any update on this?

vatsal2210 commented 3 years ago

Any updates on this fix?

AcidSlide commented 3 years ago

Is this still being updated?? Or a better question is... will this still be fixed for higher Angular versions? There's already even Angular 12 hahahahaha

cagonvinon commented 3 years ago

Hi, hope this will be updated on npm. @Crazyht Or someone to advise me another component, please?

cagonvinon commented 3 years ago

I succced integrating this as a module in an angular 12+ project. Here is project. demo-select-tree.zip

Anand-crownit commented 1 year ago

@cagonvinon this demo-select-tree working fine in angular 12+ projects but search filter is not working.