Is there anything analogous to
api.decorateCooked() for Page Publishing display of a topic?
I have some j/s in a theme component which is called by using
api.decoreateCooked(). Works great. But when I view the topic via Page Publishing, the j/s doesn’t get called. So I’m assuming that
api. method doesn’t apply.
Here’s a topic that shows it in action. Everything you see below the “Upcoming Events” H1 is not actually in the topic. That content is added into the DOM dynamically.
Here’s that same topic using Page Publishing. The stuff in the yellow box (local CSS rule styles the div explicitly) is what is literally in the topic. When it’s “cooked” the j/s replaces the DIV (see below) with other DOM elements…
So you can see what’s going on, here’s the actual DIV in the topic. The j/s in the theme component spots DIVs like this one and modifies the DOM.
<div data-custom="umbconn" data-umbconn="/vcalendar">
A list of calendar events appears here if viewed on the Podcaster Community forum at https://forum.podcaster.community/t/podcaster-community-calendar/123