• I added an <InnerBlock> with a template and templateLock={'all'} option. Within a function I add blocks and remove blocks dynamically. The problem is that adding blocks causes problems when the templateLock is set to something different than false (missing properties for example). If I hardcode the templateLock to false at the initial registerBlockType everything works like it should (Except that I don’t want it set to false all the time). Is there a way to do that programmatically?
    I am working in a custom block and used an attribute. But because my function has asynchronous elements changes to the attribute won’t change anything because the lock is called earlier.

    • This topic was modified 4 years, 11 months ago by Insomnia88. Reason: correction
Viewing 1 replies (of 1 total)
  • Moderator bcworkz

    (@bcworkz)

    Hi insomnia88 – I’m sorry no one was able to answer your question. I’m afraid I don’t have an answer for you either. It’s been a while since you posted and I’m just checking back to see if you found a solution. If you have, it’d help others if you could offer a clue. If not, hope you find some kind of solution all the same.

Viewing 1 replies (of 1 total)
  • The topic ‘Change templatelock dynamically?’ is closed to new replies.