Quantcast
Channel: Ionic Framework - Ionic Forum
Viewing all articles
Browse latest Browse all 49083

IonicServerModule: Cannot read property 'bind' of undefined

$
0
0

Hello,

I have encountered an error that I have not been able to resolve for a few days.

I just installed a new project
ionic start NewProject sidemenu --type angular

After install:

# update to Angular 11
ng update @angular/cli @angular/core rxjs
npm install @ionic/angular@latest @ionic/angular-toolkit@latest
ng add @angular-eslint/schematics

ng add @angular/pwa
ng add @nguniversal/express-engine
npm install @angular/animations
npm install @ionic/angular-server

When I launch the application everything works fine, but as soon as I add IonicServerModule in app.server.module.ts and I restart the application I have the following error message:

Cannot read property ‘bind’ of undefined at hydrateFactory (D:\www…\dist\app\server\main.js:83524:36)

I also noticed that the console displays a warning which should not be displayed since we are on Ionic 5

[DEPRECATED][ion-menu] Using the [main] attribute is deprecated, please use the "contentId" property instead:
BEFORE:
  <ion-menu>...</ion-menu>
  <div main>...</div>

AFTER:
  <ion-menu contentId="main-content"></ion-menu>
  <div id="main-content">...</div>

I also upgraded all the other packages to the latest version, the result is the same. Has anyone ever encountered this problem?

Thanks for your help.

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 49083

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>