alibaba / alibaba/flutter_boost

请问一下,集成FlutterBoost后,我要在Flutter项目全局性的监听BoostChannel的初始化工作,在哪里做合适呢?

Open
#1,573 3 comments 0 reactions 0 assignees View on GitHub
Dominant language
Dart
Stars
7.2k
Forks
1.3k
PR merge metrics
No merged PRs in 30d

Description

请问一下,集成FlutterBoost后,我要在Flutter项目中,启动后全局监听BoostChannel,即BoostChannel.instance.addEventListener,在哪里做比较合适呢?
有尝试在MyAppState.initState,会报错null异常,也就是BoostChannel.appState还没有初始化成功而报错

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by tracing BoostChannel.appState initialization and the BoostChannel.instance.addEventListener call in relation to MyAppState.initState. Confirm the lifecycle ordering that causes the null exception, then document or implement the appropriate initialization point and verify that global event listening works after FlutterBoost startup.

Written by the indexing model from the issue text.

Assessment

Tech stack
dart, flutter
Domain
mobile-dev
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.