If.bind + slot caching problem

There seems to be a problem when using if.bind in the context of multi-level “slots”.

I have created a gist to demonstrate the problem:


It can be fixed when disabling the cache of the “if.bind” attribute. This is a possible workaround, but not the solution. Does anyone know how this can be solved more robustly and elegantly?

Thanks for any help.

I think this is a case where you should use “show.bind” instead. When using “if.bind”, if false, then the component and any children will be excluded. Sounds like you expect it to appear when you toggle the boolean value, so using show.bind show give the desired behaviour.