因此,我尝试开始使用 Riverpod 并使用“点击和计数器”默认示例创建一个新的 Flutter 项目。\n一旦我添加了 pubspec
\nflutter_hooks: ^0.18.0\nhooks_riverpod: ^2.0.0\nRun Code Online (Sandbox Code Playgroud)\n和
\n\n\n导入'包:hooks_riverpod / hooks_riverpod.dart';
\n
我在调试控制台上收到此错误,但无法找出问题所在
\n: Error: Method not found: 'Error.throwWithStackTrace'.\n../\xe2\x80\xa6/framework/provider_base.dart:904\n Error.throwWithStackTrace(error, chain);\n ^^^^^^^^^^^^^^^^^^^\n: Error: A non-null value must be returned since the return type 'Never' doesn't allow null.\n../\xe2\x80\xa6/framework/provider_base.dart:898\nNever _rethrowProviderError(Object error, StackTrace stackTrace) {\n ^\nRun Code Online (Sandbox Code Playgroud)\n