Hey,
If this is a direct copy of your code there is a few typos..
id name needs to be id:name.
Also you cannot link your customrowlayout alias to the item reference which is outside your custom component..
"Unlike an ordinary property, an alias has the following restrictions:
It can only refer to an object, or the property of an object, that is within the scope of the type within which the alias is declared.
It cannot contain arbitrary JavaScript expressions
It cannot refer to objects declared outside of the scope of its type.
The alias reference is not optional, unlike the optional default value for an ordinary property; the alias reference must be provided when the alias is first declared.
It cannot refer to attached properties.
It cannot refer to properties inside a hierarchy with depth 3 or greater. "
Look here:
https://doc.qt.io/qt-5/qtqml-syntax-objectattributes.html#property-aliases
So you need to do it like this, or simlar :)
Item{
id:item
Component
{
id:componentRow
Row
{
id:someRow
Rectangle {
width:500
height:20
color:"#ff1111"
property Item context:item
Text {
anchors.horizontalCenter: parent.horizontalCenter
text: "Some text.."
}
}
}
}
Loader{
id: loaderr
sourceComponent:componentRow
}
}