render method

String render(
  1. Object? value
)

Renders any Flint renderable value to HTML.

Implementation

String render(Object? value) {
  final context = _ServerRenderContext();
  final html = _renderNode(_normalize(value), context);
  if (!includeScopedStyles || context.scopedStyles.isEmpty) return html;

  final css = context.scopedStyles.join('\n');
  return '<style data-flint-ssr-style>${_escapeHtmlText(css)}</style>$html';
}