class is a standalone component, which can not be used in the `@NgModule.bootstrap` array in...

Discussão em 'Angular' iniciado por Lisa Juliette, Dezembro 14, 2024.

  1. i got this error when i tried adding bootstrap to my angular project :


    The MainComponent class is a standalone component, which can not be used in the @NgModule.bootstrap array. Use the bootstrapApplication function for bootstrap instead
    ​

    exactly in app.module file

    bootstrap:[MainComponent] }) export class AppModule { }

    How to fix this error in order to use bootstrap in my application, thanks in advance

    Continue reading...

Compartilhe esta Página