VSCode hot reload for Flutter does not work

后端 未结 14 1279
野性不改
野性不改 2021-01-11 11:50

I\'m on VSCode right now working on my flutter application when hot reload just stops working, right in the middle of my development. I have absolutely no idea why this happ

14条回答
  •  爱一瞬间的悲伤
    2021-01-11 12:36

    Here are the official documented cases where hot reload wont work:

    1. Data regarding the sate of the app is changed (since Flutter tries to maintain the state of your app between hot reloads)
    2. Change in global variables or static field since Flutter regards them as state
    3. Changes to anything that are not in the build path (eg. initState()) and also the app's main itself
    4. You've got compilation errors, check debug console to be sure
    5. App is killed either by user or by OS because of inactivity
    6. When Enumerated types are changed to to regular classes or vise versa
    7. Font is changed
    8. When Generic type decorations are modified
    9. When included native code (Java, Kotlin or Swift) is modified
    10. CupertinoTabView builder widget

    reference: Hot Reload

提交回复
热议问题