diff --git a/packages/fwfh_webview/lib/src/web_view_factory.dart b/packages/fwfh_webview/lib/src/web_view_factory.dart index d128a0bac..cbaeee3a2 100644 --- a/packages/fwfh_webview/lib/src/web_view_factory.dart +++ b/packages/fwfh_webview/lib/src/web_view_factory.dart @@ -105,8 +105,10 @@ mixin WebViewFactory on WidgetFactory { 'min-width': '0px', 'min-height': '0px', 'width': 'auto', - if (height != null) 'height': '${height}px', - if (width != null) 'width': '${width}px', + if (height != null && width != null) ...{ + 'height': '${height}px', + 'width': '${width}px', + }, }; }, onWidgets: (meta, widgets) {