webview_win_floating 1.0.3 copy "webview_win_floating: ^1.0.3" to clipboard
webview_win_floating: ^1.0.3 copied to clipboard

WebView for Windows. A Flutter plugin that implements the interface of package webview_flutter.

example/lib/main.dart

import 'dart:io';

import 'package:flutter/material.dart';
import 'package:webview_win_floating/webview.dart';
import 'package:webview_flutter/webview_flutter.dart';

void main() {
  if (Platform.isWindows) WebView.platform = WindowsWebViewPlugin();
  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({Key? key}) : super(key: key);

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {

  @override
  void initState() {
    super.initState();
  }

  late WebViewController controller;
  @override
  Widget build(BuildContext context) {

    Widget webview = WebView(
      initialUrl: "https://www.youtube.com/",
      javascriptMode: JavascriptMode.unrestricted,
      onWebViewCreated: (controller) {
        this.controller = controller;
      },
    );

    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Windows Webview example app'),
        ),
        body: webview,
      ),
    );
  }
}
14
likes
0
pub points
86%
popularity

Publisher

unverified uploader

WebView for Windows. A Flutter plugin that implements the interface of package webview_flutter.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter, fullscreen_window, plugin_platform_interface, webview_flutter_platform_interface

More

Packages that depend on webview_win_floating