import 'package:flutter/material.dart';
void main() {
runApp(MaterialApp(
home: Scaffold(body:LoginPage())
));
}
class LoginPage extends StatelessWidget {
const LoginPage({Key key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Container(
decoration: BoxDecoration(
image: DecorationImage(
image:AssetImage("assets/images/bg.jpg"),
fit:BoxFit.cover,
),
),
child:Center(
child:Text(
'Hello Wolrd',style:TextStyle(
fontSize: 22.0,
color: Colors.black
),
)
),
);
}
}
网友评论