BBCode
BBCode ("Bulletin Board Code") is a lightweight markup language used to format messages in many Internet forum software.
Language Info
Name
bbcode
Extensions
.bbcode, .bb
Editor
markup
Compiler
BBob.
Version
BBob: v3.0.2
Example Usage
show code
- JS
- TS
- React
- Vue
- Svelte
- Solid
import { createPlayground } from 'livecodes';
const options = {
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
};
createPlayground('#container', options);
import { createPlayground, type EmbedOptions } from 'livecodes';
const options: EmbedOptions = {
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
};
createPlayground('#container', options);
import LiveCodes from 'livecodes/react';
export default function App() {
const options = {
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
};
return (<LiveCodes {...options}></LiveCodes>);
}
<script setup>
import LiveCodes from "livecodes/vue";
const options = {
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
};
</script>
<template>
<LiveCodes v-bind="options" />
</template>
<script>
import { onMount } from 'svelte';
import { createPlayground } from 'livecodes';
let options = $state({
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
});
let container = $state(null);
onMount(() => {
createPlayground(container, options);
});
</script>
<div bind:this="{container}"></div>
import { createPlayground, type EmbedOptions } from 'livecodes';
export default function App() {
const options: EmbedOptions = {
"config": {
"markup": {
"language": "bbcode",
"content": "[i]Text[/i]"
}
},
"params": {
"compiled": "open"
}
};
const onMounted = (container: HTMLElement) => {
createPlayground(container, options);
};
return <div ref={onMounted}></div>;
}