Skip to content

Commit

Permalink
Merge pull request #3843 from neos/task/remove-ui-script-tag-neos-9-f…
Browse files Browse the repository at this point in the history
…ollowup

TASK: remove ui script tag neos 9 followup
  • Loading branch information
mhsdesign authored Sep 16, 2024
2 parents d82f947 + 3cfdefa commit 93bd781
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions packages/neos-ui-guest-frame/src/initializeGuestFrame.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,6 @@ export default ({globalRegistry, store}) => function * initializeGuestFrame() {
return;
}

// Load legacy node data scripts from guest frame - remove with Neos 9.0
const legacyNodeData = guestFrameWindow['@Neos.Neos.Ui:Nodes'] || {};

// Load all nodedata for nodes in the guest frame and filter duplicates
const {q} = yield backend.get();
const nodeContextPathsInGuestFrame = findAllNodesInGuestFrame().map(node => node.getAttribute('data-__neos-node-contextpath'));
Expand All @@ -83,7 +80,6 @@ export default ({globalRegistry, store}) => function * initializeGuestFrame() {

const nodes = Object.assign(
{},
legacyNodeData, // Merge legacy node data from the guest frame - remove with Neos 9.0
fullyLoadedNodesFromContent,
{
[documentInformation.metaData.documentNode]: documentInformation.metaData.documentNodeSerialization
Expand All @@ -93,9 +89,6 @@ export default ({globalRegistry, store}) => function * initializeGuestFrame() {
// Merge new nodes into the store
yield put(actions.CR.Nodes.merge(nodes));

// Remove the legacy inline scripts after initialization - remove with Neos 9.0
Array.prototype.forEach.call(guestFrameWindow.document.querySelectorAll('script[data-neos-nodedata]'), element => element.parentElement.removeChild(element));

const state = store.getState();

// Set the current document node to the one that is rendered in the guest frame which might be different from the one that is currently selected in the page tree
Expand Down

0 comments on commit 93bd781

Please sign in to comment.