0

After upgrading to Angular RC.3 and switching to Ivy in a project I get the following error:

Error: dialog is not a known element: 1. If dialog is an Angular component, then verify that it is part of this module. 2. To allow any element add NO_ERRORS_SCHEMA to the @NgModule.schemas of this component.

Indeed I have a markup like this using a <dialog>-element:

<dialog [attr.open]="open ? '' : null"></dialog>

Even though the browser coverage is not 100% dialog is still a valid HTML element.

Did they miss to support it? Is this a bug in Anglaur or Ivy? Can I only use the dialog-element, when I also use NO_ERRORS_SCHEMA in the components?*

* Which I actually don't want to activate.

lampshade
  • 2,470
  • 3
  • 36
  • 74
  • Can you show some code? – Glenn van Acker Nov 28 '19 at 13:42
  • Thanks for your feedback, @GlennvanAcker. What else do you need? I'm happy to provide it. As stated in the question I have `` HTML in the template of a component. There's actually not more to it. :) – lampshade Nov 28 '19 at 14:43
  • what approach did you take to upgrade to angular rc3, and what browser are you using. it's strange, it seems to be right... Also, do you get any other errors, when you comment out the dialog? – Glenn van Acker Nov 28 '19 at 15:01
  • I upgraded from 8.1 to 8.2 and then to 9 RC.3, as described on the Angular upgrade guide. No, there are no other errors. I changed the element to a `div` for now. – lampshade Nov 28 '19 at 15:22
  • 2
    I tried to reproduce your error but was not able to. Could you reproduce the error on stackblitz project, and share it here? Also, you might want to double-check your package.json dependencies to see if they are the same version that an `ng new` project installs with @angular/cli@next. Also check if the problem persists with v9-rc.4. – Mezo Istvan Nov 28 '19 at 16:11
  • try running an npm update, to see if that resolves the issue. – Glenn van Acker Nov 29 '19 at 09:57

0 Answers0