<campaign-display
class="campaign-display-drawerered"
preamble-text="{{ special_coverage.name }} by"
src="{% content_tunic_campaign_url special_coverage.tunic_campaign_id %}"
placement="recirc"
name-only
no-link
no-pixel lazy>
</campaign-display>
The lazy
flag would make sure that the fetchCampaign
method doesn't execute when the node is attached to the DOM.
We would add attributeChangedCallback
to make this call, e.g.:
attributeChangedCallback (name, previousValue, value) {
if (!lazy && this.props.src) { // pseudo code
this.store.actions.fetchCampaign(this.props.src);
}
}