Migrate existing Angular 8 project to version 12 with the PR


Topic: Migrate existing Angular 8 project to version 12 with the PRO kit and get compilation errors on MDB components.

JeroenVunderink pro premium asked 3 years ago

Expected behavior No compilation errors.

Actual behavior I upgrade my mac to angualr 12. Download the MDB 12 pro files. Started a new project like described on the website Recreated/deployed my code in the new project

After this I get compilation errors. Looked at the support site but do not have the solution. Feel pretty stupid, but do you have an idea what to do to get rid of these errors and make my Angular 8 project now work in my Angular 12 project? Would be very much appreciated!

Resources (screenshots, code snippets etc.)

src/app/pages/news/news.component.ts:10:16 10 templateUrl: './news.component.html', ~~~~~~~~~~~~~~~~~~~~~~~ Error occurs in the template of component NewsComponent.

Error: src/app/pages/news/news.component.html:10:5 - error NG8002: Can't bind to 'displayValue' since it isn't a known property of 'mdb-auto-completer'. 1. If 'mdb-auto-completer' is an Angular component and it has 'displayValue' input, then verify that it is part of this module. 2. If 'mdb-auto-completer' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message. 3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

10 [displayValue]="onDisplayFatherValue"> ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

src/app/pages/news/news.component.ts:10:16 10 templateUrl: './news.component.html', ~~~~~~~~~~~~~~~~~~~~~~~ Error occurs in the template of component NewsComponent.

Error: src/app/pages/news/news.component.html:11:5 - error NG8001: 'mdb-option' is not a known element: 1. If 'mdb-option' is an Angular component, then verify that it is part of this module. 2. If 'mdb-option' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.


Arkadiusz Idzikowski staff commented 3 years ago

@JeroenVunderink It looks like Angular does not recognize AutoCompleterModule. Did you import this module (or MDBBootstrapModulesPro.forRoot()) in your module file?

Please try to remove node_modules and package-lock file and reinstall dependencies with npm install.


Please insert min. 20 characters.

FREE CONSULTATION

Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.

Status

Open

Specification of the issue
  • User: Pro
  • Premium support: Yes
  • Technology: MDB Angular
  • MDB Version: MDB4 12.0.0
  • Device: Mac
  • Browser: Chrome
  • OS: MacOS Monterey
  • Provided sample code: No
  • Provided link: No