WTH can I not pass parameters to a subview to reuse them for several entities

I would like to create a subview for example for lights for a room. But I do not want to create a subview for every room. My lights and other thing are following the same naming principles per room for example “kitchen main light”, “living main light”, also other things related to light. I also have that for humidity info, roller shutter and other things. If I could pass a parameter to a subview and use it there then I would only need 1 subview for light, 1 for roller shutter and other and could just pass parameter for the room.

I’m searching for a way like this too.

Did you find a workaround yet?