Reusable component not showing up, js errors

Created a component and made it reusable… then added it to a design. In the preview, the component isn’t there and there are several errors in the console along the lines of:

“Component with uid: ‘bf655e0fede3ba02d55670920007b495’ already registered for another node!” (there are 7 such errors, each with a different uid).

Something not working or did I do something wrong? (App ID AE4235E1-DBB7-C6F0-FF4A-E0378B0B2B00)

Hello @Alex_Klein

I opened a preview of your pages with reusable components and did not see this error. Can you please provide steps to reproduce the problem in your application?

Regards,
Inna

Hi Inna,

The page is “basicLayout”. Have reusable component “navButton” but it doesn’t appear in preview. Using inspect tool in Chrome, I see 6 warnings along the lines of “Component with uid: ‘38c4bbc4c01d0b25ecd64b15f81bfae3’ already registered for another node!” (message @ sdk.js:14)

Hello @Alex_Klein

Your reusable component receives some values from pageData for content, but there is nothing for it.
Example PUBLIC receives value for content from pageData.navName


And other have the same issue

UI Builder - Ubindi - Backendless 🔊 2022-12-21 16-11-27

UI Builder - Ubindi - Backendless 🔊 2022-12-21 16-11-47

But on page “basicLayout” in the “pageData” you don’t have “navName” or “navIcon”

Regards

Thanks for having a look at things Viktor — but I set these properties/values on “on before page enter”:

When I print page data object, I see these things are there. Also, can you comment on the warnings I see in the console such as "Component with uid: ‘38c4bbc4c01d0b25ecd64b15f81bfae3’ already registered for another node!” ?

Thank you again :slight_smile:

@Alex_Klein

Warnings indicate that there is duplication of nodes, this can happen when a component is used in a repeater or reusable several times.

You use reusable component. I think it is ok. You can set “display: false” to the component to make sure

Regards

Hi Viktor, hm, so I should ignore the warnings (which seem very strange… but ok). However, I still do not understand why my component is not appearing at all. It is set to display, and I do have values going to the component from page data. But it is not in the preview?!

@Alex_Klein

Go to the reusable component editor. And edit “content logic” like this:

That works! Thank you :green_heart:
I see/understand now that individual components inside of my reusable component bind to data in the reusable component data model (because I had “data container” checked). Sorry for being a little dumb :roll_eyes: