Template repeater initial state

Trying to set what templates that’s enabled when a window is opened. Using custom properties and the property changed event and it all seems to work fine WHEN the window has been opened, just not the first time. After a little debugging I figured that .getLoadedTemplates() returns 0, even when filtering on the componentRunning property which seems to be the last property that change on the repeater when the window opens.

Any suggestions?

Figured it out, modifying the templateParams property on the repeater works as intended.