i want to change text direction of whole app right to left
my main code is :
void main() {
runApp(MyApp());
}
class MyApp extends StatelessWidget {
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return ChangeNotifierProvider(
create: (context)=>HomeModel(),
child: MaterialApp(
debugShowCheckedModeBanner: false,
home: Directionality(
textDirection:
TextDirection.rtl,
child: FirstScreen()),
));
}
}
but only first screen view is right to left and when navigate to second page again it is from left to right .