Movatterモバイル変換


[0]ホーム

URL:


  • Preparing search index...
  • The search index is not available
bbcode-ast

bbcode-ast

bbcode-ast

Generates an Abstract Syntax Tree (AST) from a chunk of BBCode.

Read full and updated documentation:https://pythoncoderas.github.io/bbcode-ast/

Installation

Node.js

npminstall--savebbcode-ast

Browser

Load the library fromhttps://cdn.jsdelivr.net/npm/bbcode-ast@2/dist/bundle.min.js.

This will add abbcode_ast variable to thewindow global. The default parser can be accessed throughbbcode_ast.default.

Usage

You can either use the default parser or construct your own parser. Once you have aParser, call theparse method onit. The default parser can be imported.

It will return the root node of the AST.

You can navigate through the tree by accessing thechildren attribute of the root node and recursively inspectingthechildren of child nodes.

Settings

Member Visibility

Theme

On This Page

Generated usingTypeDoc


[8]ページ先頭

©2009-2025 Movatter.jp