본문 바로가기

분류 전체보기27

Flutter lifecycle | 플러터 생명주기 Flutter LifeCycle LifeCycle?라이프 사이클은 각 위젯이 얼만큼의 시간동안 동작하는지 이해하기에 좋은 개념이다.잘 알아두면 퍼포번스 부분에도 큰 영향을 끼친다.Stateful widget순서Constructor|createState()|initState()|didChangeDependencies()|Build()순서로 라이프 사이클이 이어져간다. 추가적으로 종료될 때 dispose()가 호출된다.setState(): 위젯에서 state가 변경될 대 호출되고 빌드를 한다.didUpdateWidget(): 부모 위젯에서 업데이트가 발생하면 호출되고 빌드를 한다.constructor생성자, 멤버변수에서 부모로부터 받은 변수를 넣어주는 작업을 해준다.createState()statefulWi.. 2024. 3. 2.
Flutter Setstate 개념 정리 | StatefulWidget 내 setState flutter setStatesetState애 대해 이해하기 전에 StatefulWidget을 알아야한다.StatefulWidgetStatefulWidget은 변경될 수 있는 상태를 가지고 있는 위젯이다. React의 useState와 유사한 개념인것 같다. 여기서 상태는 위젯이 빌드되는 동시에 읽을 수 있고, 위젯의 생명 주기동안 변경할 수 있는 정보를 말한다.StatefulWidget은 UI의 일부분이 동적으로 변화할 때 유용하게 사용한다.class Example extends StatefulWidget { Example({Key? key}) : super(key: key); @override _ExampleState createState() => _ExampleState(); // State .. 2024. 3. 1.
Flutter 개발 참고 사이트 정보 | 플러터 스터디 자료 Fluuter 개발 참고 사이트공식 사이트flutter.devdart.dev dartpad 사용해  unit 테스트 가능pub.dev 에서 필요한 패키지 install 해서 필요한 기능  Flutter - Build apps for any screenFlutter transforms the entire app development process. Build, test, and deploy beautiful mobile, web, desktop, and embedded apps from a single codebase.flutter.dev  Dart programming languageDart is an approachable, portable, and productive language for high.. 2024. 2. 18.