Currently usages of Neos.Neos:PrimaryContent are not replaced automatically.
Instead a comment is added to the top of using files:
// TODO 9.0 migration: You need to refactor "Neos.Neos:PrimaryContent" to use "Neos.Neos:ContentCollection" instead.
// ...
main = Neos.Neos:PrimaryContent
Instead, we could consider replacing those usages directly.
Danger: With the current rectors it's not possible yet, to only replace the usages of the prototypes.. If we were to use the FusionReplacePrototypeNameRector to replace PrimaryContent, overrides such as
prototype(Neos.Neos:PrimaryContent) {
someCustomCase {
condition = ...
renderer = 'this will be lost'
}
}
would be replaced, too.
So, we would need to extend the FusionReplacePrototypeNameRector by some flag that allows us to exclude prototype definitions. Also we should extend other rectors like FusionPrototypeNameAddCommentRector such that the can target only prototype definitions/overrides.
Alternatively we should just keep Neos.Neos:PrimaryContent usages for now since the prototype still exists in 9.0 (even if deprecated)
Currently usages of
Neos.Neos:PrimaryContent
are not replaced automatically.Instead a comment is added to the top of using files:
Instead, we could consider replacing those usages directly.
Danger: With the current rectors it's not possible yet, to only replace the usages of the prototypes.. If we were to use the
FusionReplacePrototypeNameRector
to replacePrimaryContent
, overrides such aswould be replaced, too.
So, we would need to extend the
FusionReplacePrototypeNameRector
by some flag that allows us to exclude prototype definitions. Also we should extend other rectors likeFusionPrototypeNameAddCommentRector
such that the can target only prototype definitions/overrides.Alternatively we should just keep
Neos.Neos:PrimaryContent
usages for now since the prototype still exists in 9.0 (even if deprecated)Relates: