작성
·
250
2
import 'package:flutter/material.dart';
import 'package:webview_flutter/webview_flutter.dart';
class HomeScreen extends StatelessWidget {
final homeUrl = Uri.parse('https://blog.codefactory.ai');
final WebViewController controller = WebViewController();
HomeScreen({super.key}) {
controller.loadRequest(Uri.parse('https://blog.codefactory.ai'));
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Blug App Bar'),
centerTitle: true,
backgroundColor: Colors.orange,
),
body: WebViewWidget(
controller: controller,
),
);
}
}
이렇게하시면 됩니당