Add the asset to the pubspec.yaml
import 'package:flutter/material.dart';
void main() {
runApp(
MaterialApp(
home: Scaffold(
backgroundColor: Colors.blueGrey,
appBar: AppBar(
title: Text("National Park"),
backgroundColor: Colors.blueGrey[900],
),
body: Center(
child: Image(image: AssetImage('images/bird.png')),
),
),
),
);
}
No comments:
Post a Comment