メインコンテンツまでスキップ

Inline Flutter Widget

You can insert costom Flutter Widget in any where of your markdon.


How to

Use {{WIDGET_NAME}}.

example

# Title

this is some text.

{{MyWidget}}

this is some text.

Register MyWidget in Flutter

Open FLUTTER/lib/widgets.dart.


final CometInlineWidgets inlineWidgets = {
...
'MyWidget': (_) => MyWidget(), // add this line
...
};

Constraints

Bad

Like this {{MyWidget}} nomal text cannot be mixed in the same line


Bad

{{MyWidget}} {{MyWidget}}


Bad

Don't put leading space
{{MyWidget}}

Note
{{MyWidget}}
and
{{ MyWidget }}
are different widget name.