Skip to content

Instantly share code, notes, and snippets.

@owaineevans
Created November 15, 2021 06:15
Show Gist options
  • Save owaineevans/c4e0314fa32704644973b42ea697bca1 to your computer and use it in GitHub Desktop.
Save owaineevans/c4e0314fa32704644973b42ea697bca1 to your computer and use it in GitHub Desktop.
AutoComplete bug
import 'package:flutter/material.dart';
import 'package:flutter/services.dart';
void main() {
WidgetsFlutterBinding.ensureInitialized();
runApp(const TestScreen());
}
class TestScreen extends StatelessWidget {
const TestScreen({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Material(
child: Column(
children: [
TextFormField(
decoration:
const InputDecoration(labelText: 'Enter your email address'),
autofillHints: const [AutofillHints.email],
onChanged: (value) {
print(value);
},
),
TextFormField(
decoration: const InputDecoration(labelText: 'Enter password'),
autofillHints: const [AutofillHints.password],
onChanged: (value) {
print(value);
},
),
],
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment