mirror of
https://github.com/flarum/core.git
synced 2025-08-05 16:07:34 +02:00
TextFormatterPreview: Add documentation
This commit is contained in:
@@ -2,6 +2,16 @@
|
|||||||
|
|
||||||
import Component from '../../common/Component';
|
import Component from '../../common/Component';
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The `TextFormatterPreview` component renders Markdown as HTML using the
|
||||||
|
* TextFormatter library, polling a data source for changes every 50ms. This is
|
||||||
|
* done to prevent expensive redraws on e.g. every single keystroke, while
|
||||||
|
* still retaining the perception of live updates for the user.
|
||||||
|
*
|
||||||
|
* ### Attrs
|
||||||
|
*
|
||||||
|
* - `content` A callback that retrieves the latest content that should be rendered.
|
||||||
|
*/
|
||||||
export default class TextFormatterPreview extends Component {
|
export default class TextFormatterPreview extends Component {
|
||||||
view() {
|
view() {
|
||||||
return <div className="Post-preview" />;
|
return <div className="Post-preview" />;
|
||||||
|
Reference in New Issue
Block a user