Skip to content

NgModule decorator outside module function #484

Open
@bertdewolf

Description

@bertdewolf

In for example ngx-bootstrap-multiselect.umd.js I see:

var NgxBootstrapMultiselectModule = /** @class */ (function () {
    function NgxBootstrapMultiselectModule() {
    }
    return NgxBootstrapMultiselectModule;
}());

NgxBootstrapMultiselectModule.decorators = [
    { type: core.NgModule, args: [{
                declarations: [
                    NgxDropdownMultiselectComponent,
                    MultiSelectSearchFilter,
                    AutofocusDirective,
                    OffClickDirective
                ],
                imports: [
                    common.CommonModule,
                    forms.ReactiveFormsModule
                ],
                exports: [
                    NgxDropdownMultiselectComponent,
                    MultiSelectSearchFilter,
                ],
            },] }
];

For angular 14 ngcc to work correctly, the NgModule decorators should be within the NgxBootstrapMultiselectModule function.
This in turn causes for errors like 'NgxBootstrapMultiselectModule does not have a module def (ɵmod property)'

With which typescript version was this bundle packaged?

I cannot play with it myself since not everything for angular cli is in this repo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions