Issue #2047Opened May 30, 2019by alikabeer323 reactions

[SOLVED] I need A custom category of blocks to appear in another panel/div

Question

I could use appendto to move the ALL the blocks anywhere I want but how do I move a particular category of blocks. I need them to appear seperately.

Answers (1)

alikabeer32May 30, 20193 reactions
Code SnippetTEXT
Nvm found the solution
define your category like so
blockManager.get('my_block').set('category', 'custom_defined_category');
 and then
const blocks = blockManager.getAll();
const filtered = blocks.filter(block => block.get('category') == 'custom_defined_category')
const newBlocksEl = blockManager.render(filtered,{ external: true });
document.getElementById('some-id').appendChild(newBlocksEl);

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.