기존 프로젝트 최초 업로드
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
// 🚪 앱 진입점. Firebase/백그라운드 감시 서비스 초기화 후 로그인 화면으로 시작한다.
|
||||
// 실제 화면 구현은 lib/screens/ 폴더, 공통 설정은 lib/config.dart 참고.
|
||||
import 'dart:io';
|
||||
import 'package:flutter/foundation.dart' show kIsWeb;
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:firebase_core/firebase_core.dart';
|
||||
import 'firebase_options.dart';
|
||||
import 'config.dart';
|
||||
import 'pocket_watch_service.dart';
|
||||
import 'screens/login_screen.dart';
|
||||
|
||||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
await Firebase.initializeApp(options: DefaultFirebaseOptions.currentPlatform);
|
||||
await printFCMToken();
|
||||
if (!kIsWeb && Platform.isAndroid) {
|
||||
await initializePocketWatchService();
|
||||
}
|
||||
runApp(const SchoolAttendanceApp());
|
||||
}
|
||||
|
||||
class SchoolAttendanceApp extends StatelessWidget {
|
||||
const SchoolAttendanceApp({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
debugShowCheckedModeBanner: false,
|
||||
title: '백산고등학교 학생 도우미',
|
||||
theme: ThemeData(primarySwatch: Colors.indigo, useMaterial3: true),
|
||||
home: const LoginScreen(), // 🚪 앱을 켜면 무조건 로그인 화면이 먼저 등장합니다.
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user