Let's assume that I have a music player block and it's working fine. I now want to add another block for playlists and I want to use this single player block in this block. Is it possible to import this block into my playlist or should I just create a duplicate of all files in my playlist block?
1 Answer
Yes, you can create custom blocks with InnerBlocks. If you only want the parent block to include music player blocks, you can define that in ALLOWED_BLOCKS. https://developer.wordpress.org/block-editor/how-to-guides/block-tutorial/nested-blocks-inner-blocks/
-
Actually, I don't want the users to be able to use the single player in the album player. I want to just use it in code. So when a user selects 3 music, it automatically creates an album player with this single player.Amirition– Amirition2022-06-28 13:31:39 +00:00Commented Jun 28, 2022 at 13:31