WebViewScaffold is the flutter WebView plugin. If you want to open any web page without using your device’s browser then you can do it easily using WebViewScaffold widget.
Properties Of WebViewScaffold :
- url: The url which we want to search.
- appBar: The add appBar in our flutter application.
- withZoom: If you allow your web page to zoom-in or zoom-out then put it true otherwise false.
- initialChild: It is used to add your own widget while webpage loads.
- hidden: If true then show us CircularProgressIndicator while webpage loads.
- Add flutter_webview_plugin in dependencies in pubspec.yaml file.
- Now come back to main.dart file.
- initially url is “https://google.com” and when app starts, this url will be loaded.
- When user type the url and press enter then searchURL() will be called and requested url will be loaded.
- If user wants to go back, press arrow_back key.
- If you want to add your own initial child then uncomment the initialChild and add your widget.
- set withZoom = true if you allow your webpage to zoom-in or zoom-out.
- Getting Started with Cross-Platform Mobile Application using Flutter
- Difference Between Rows and Columns vs Container in Flutter
- What is widgets in Flutter?
- Container class in Flutter
- Difference Between Stateless and Stateful Widget in Flutter
- Rive animations in Flutter
- ProgressIndicator in Flutter
- Row and Column Widgets in Flutter with Example
- Flutter - Stateful vs Stateless Widgets
- Wrap Widget in Flutter
- Listview.builder in Flutter
- Splash Screen in Flutter
- How to Add images in Flutter App?
- A Hello World App using Flutter
- Raised Button widget in Flutter
- endDrawer Widget in Flutter
- Fluttertoast in Flutter
- Designing a Form Submission Page in Flutter
- Creating a Simple Application in Flutter
- Customizing Fonts in Flutter
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.