Is possible to use some widgets from flutter/cupertino.dart
inside a material app? (Using the Scaffold
)
I want to render the Switch
widget with the cupertino style instead the material.
Is possible to use some widgets from flutter/cupertino.dart
inside a material app? (Using the Scaffold
)
I want to render the Switch
widget with the cupertino style instead the material.
yes you can just import flutter/cupertino.dart
and use it like this:
import 'package:flutter/cupertino.dart';
Scaffold(
body:Column(
children:<Widget>[
CupertinoSwitch(
value: value,
onChanged: (val){
setState(() {
value = val;
});
},
)
]
)
)