daum_postcode_view 0.1.2 daum_postcode_view: ^0.1.2 copied to clipboard
Daum Postcode View Widget Package for Flutter.
import 'package:daum_postcode_view/daum_postcode_view.dart';
import 'package:flutter/material.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: const PostcodePage(),
);
}
}
class PostcodePage extends StatelessWidget {
const PostcodePage({super.key});
@override
Widget build(BuildContext context) {
return Scaffold(
body: DaumPostcodeView(
onComplete: (model) {
Navigator.of(context).pop(model);
},
options: const DaumPostcodeOptions(
animation: true,
hideEngBtn: true,
themeType: DaumPostcodeThemeType.darknessTheme,
),
),
);
}
}