Skip to content
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

Support for Standalone components #74

Open
AbdealiLoKo opened this issue May 11, 2023 · 2 comments
Open

Support for Standalone components #74

AbdealiLoKo opened this issue May 11, 2023 · 2 comments

Comments

@AbdealiLoKo
Copy link

I was trying to write a standalone component in angular 15
And I tried:

@Component({
    selector: 'my-login',
    templateUrl: './login.component.html',
    styleUrls: ['./login.component.scss'],
    standalone: true,
    imports: [SharedModule, FeatherModule.pick(ChevronRight)],
})

Which gives the error:

imports' contains a ModuleWithProviders value, likely the result of a 'Module.forRoot()'-style call. These calls are not used to configure components and are not valid in standalone component imports - consider importing them in the application bootstrap instead

So, I was wondering how can I use this package with standalone components ?

@TejasCMehta
Copy link

Any solution or work around for this?

@jatingarala
Copy link

add importProvidersFrom(FeatherModule.pick(allIcons)) in app.config.jts file

image

and in your standalone component import FeatherModule

image

Thats it!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants