Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

167
Views
"Can't bind to (...)" and "(...) is not a known element" JS errors when Angular app rendered within a Liferay portlet

I have an Angular 9 app that I would like to make accessible via Liferay 7.x portlet.

When I follow these steps, deploy my portlet and try to render it, I run into issues (reported as JavaScript errors in the browser console):

A. "Can't bind to 'X' since it isn't a known property of 'Y'.

B. "'X' is not a known element:

  1. If 'X' is an Angular component, then verify that it is part of this module.
  2. If 'X' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message." The problem is that as far as I can see the modules in question are properly annotated and listed as exports, declarations, etc.

I would appreciate help with resolving these issues. I am happy to jump on a Zoom to demonstrate the details of my config.

Thank you!

about 4 years ago · Juan Pablo Isaza
2 answers
Answer question

0

You can find the answer here: https://angular.io/guide/ngmodule-faq#what-does-cant-bind-to-x-since-it-isnt-a-known-property-of-y-mean

What does "Can't bind to 'x' since it isn't a known property of 'y'" mean? This error often means that you haven't declared the directive "x" or haven't imported the NgModule to which "x" belongs.

Perhaps you declared "x" in an application sub-module but forgot to export it. The "x" class isn't visible to other modules until you add it to the exports list.

about 4 years ago · Juan Pablo Isaza Report

0

My problems were related to the fact that:

  1. The these steps ask to remove "selector" properties, which is incorrect. When I restored the "selector" properties the problem #1 went away
  2. I was ineed missing some module references (problem #2)

Hopefully this helps others, too.

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!