How to use the @bbob/plugin-helper.isStringNode function in @bbob/plugin-helper

To help you get started, we’ve selected a few @bbob/plugin-helper examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github JiLiZART / bbob / packages / bbob-react / src / render.js View on Github external
const els = [].concat(nodes).reduce((arr, node, index) => {
    if (isTagNode(node)) {
      arr.push(tagToReactElement(node, index));
    } else if (isStringNode(node)) {
      arr.push(node);
    }

    return arr;
  }, []);
github JiLiZART / bbob / packages / bbob-preset-html5 / src / defaultTags.js View on Github external
content.forEach((el) => {
    if (isStringNode(el) && isStartsWith(el, '*')) {
      if (listItems[listIdx]) {
        listIdx++;
      }
      ensureListItem(createItemNode());
      addItem(el.substr(1));
    } else if (isTagNode(el) && TagNode.isOf(el, '*')) {
      if (listItems[listIdx]) {
        listIdx++;
      }
      ensureListItem(createItemNode());
    } else if (!isTagNode(listItems[listIdx])) {
      listIdx++;
      ensureListItem(el);
    } else if (listItems[listIdx]) {
      addItem(el);
    } else {