How to use the @bbob/preset-html5.extend function in @bbob/preset-html5

To help you get started, we’ve selected a few @bbob/preset-html5 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-preset-react / src / index.js View on Github external
import presetHTML5 from '@bbob/preset-html5';

export default presetHTML5.extend(tags => ({
  ...tags,

  b: (...args) => ({
    ...tags.b(...args),
    attrs: {
      style: { fontWeight: 'bold' },
    },
  }),

  i: (...args) => ({
    ...tags.b(...args),
    attrs: {
      style: { fontStyle: 'italic' },
    },
  }),

@bbob/preset-html5

HTML5 preset to transform BBCode to HTML for @bbob/parser

MIT
Latest version published 3 months ago

Package Health Score

78 / 100
Full package analysis

Popular @bbob/preset-html5 functions