In this example, I'm going to share the code on how to add Border Radius to a Container.
Here is how the final output is going to look.
Here is the code that you need to run this example.
import 'package:flutter/material.dart';
void main() => runApp(MyApp());
class MyApp extends StatefulWidget {
@override
_MyAppState createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
double padValue = 0;
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: Text("Border Radius to Container"),
),
body: Container(
margin: EdgeInsets.all(100.0),
decoration: BoxDecoration(
color: Colors.orange,
shape: BoxShape.rectangle,
borderRadius: BorderRadius.only(
topLeft: Radius.circular(25.0),
bottomRight: Radius.circular(25.0))),
)),
);
}
}
Thanks,
Srikanth