onInit method
Called immediately after the widget is allocated in memory. You might use this to initialize something for the controller.
Implementation
@override
void onInit() async {
super.onInit();
junpTolastPage();
if (!kIsWeb) {
_dir = await getApplicationDocumentsDirectory();
if (GetStorage().read(_StorageConstants().fontsSelected) == 1 ||
state.fontsSelected.value == 1) {
await initFontLoader();
}
}
await prepareFonts(state.currentPageNumber.value - 1);
searchFocusNode = FocusNode();
searchTextController = TextEditingController();
}