2
0
mirror of https://github.com/tenrok/BBob.git synced 2026-05-27 14:45:03 +03:00
Files
bbob/packages/bbob-preset
Nikolay Kost 3575982b28 chore: pnpm support (#199)
* feat: initial pnpm support

* feat: lock files

* fix: github actions

* fix: lerna bootstrap

* fix: lerna useWorkspaces

* fix: lerna no ci

* fix: lint

* fix: audit

* chore: changeset

* fix: publish action
2023-10-23 13:21:56 +02:00
..
2021-05-19 19:41:56 +02:00
2021-05-19 19:41:56 +02:00
2020-01-22 20:25:42 +02:00
2021-11-29 00:33:06 +02:00
2023-10-23 13:21:56 +02:00

#@bbob/preset Base function for create presets to process bbcode AST to HTML or Framework specific tags

Install

npm i @bbob/preset

API

For plain HTML

import { createPreset } from '@bbob/core'

import { createPreset } from '@bbob/preset'

const options = {
    onlyAllowTags: ['url', 'h'],
    onError: (err) => console.warn(err.message, err.lineNumber, err.columnNumber)
};
const pre = parse('[url=https://github.com]hello world![/url]', options)

Usage