Skip to content

Flutter AnimationController vsync 错误 #4

@devImpChen

Description

@devImpChen

这两天想着看一下fun_android_flutter的代码,但是下载下来之后

AnimationController(duration: Duration(seconds: 3), vsync: this);

发生错误如下

- The named parameter 'vsync' isn't defined.

解决办法

in your pubspec.yml

change this to :

environment:
  sdk: ">=2.8.0 <3.0.0"

and flutter pub get

重启下 Android Studio

参考链接:
sf
github

Metadata

Metadata

Assignees

No one assigned

    Labels

    FlutterFlutter笔记集合

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions