flutter_html_iframe
3.0.0, released 2 years ago by sub6resources.com
Renders <iframe> tags in flutter_html using webview_flutter.
What it does
This package provides an IframeHtmlExtension that lets flutter_html render <iframe> elements via the webview_flutter plugin. It respects width, height, and sandbox attributes and allows a navigationDelegate to control URL loading.
AI-written summary of version 3.0.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to display iframe content inside a flutter_html widget.
- You want sandboxed or unrestricted JavaScript control for the iframe.
- You need to block or allow navigation within the iframe via a delegate.
Skip it when
- You are targeting web only, as webview_flutter is not supported on web.
- You do not need iframe support in your HTML rendering.
Strengths
- Seamless integration with flutter_html.
- Supports sandbox and navigationDelegate for security and control.
- Stable release with recent updates.
- No additional code generation required.
Weaknesses
- Only works on platforms supported by webview_flutter (Android, iOS, macOS).
- Does not support web platform.
- Requires adding webview_flutter dependency.
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 4
Add flutter_html_iframe to pubspec, import, and register IframeHtmlExtension in Html widget.
Widget html = Html(
extensions: {
IframeHtmlExtension(),
}
);Alternatives
Packages that do the same job and could replace flutter_html_iframe.
- flutter_widget_from_html
Render HTML content as native Flutter widgets with support for common tags, CSS, and media.
89Compare - flutter_widget_from_html_core
Render HTML content as native Flutter widgets with correctness and extensibility.
92Compare - fwfh_url_launcher
WidgetFactory mixin to launch links in HTML widgets via url_launcher.
74Compare - simple_html_css
Convert simple HTML and inline CSS styles into RichText or TextSpan widgets.
50Compare
Works with
Packages commonly used together with flutter_html_iframe: ones it builds on, ones built on it, and its own family.
- webflutter_html_iframe depends on itLightweight bindings for browser APIs via JS interop
- htmlflutter_html_iframe depends on itA Dart implementation of an HTML5 parser for strings and bytes.
- webview_flutterflutter_html_iframe depends on itFlutter plugin that embeds a native WebView widget.
- flutter_htmlflutter_html_iframe depends on itRenders static HTML and CSS as Flutter widget trees.
- flutter_html_tableSame familyRenders HTML table tags within the flutter_html package using flutter_layout_grid.
- flutter_html_mathSame familyRenders <math> tags in flutter_html using flutter_math_fork.
- flutter_html_allBuilt on flutter_html_iframeConvenience package exporting all optional flutter_html widgets.