
回复
以path_provider举例:
在引用的项目中,pubspec.yaml中dependencies新增配置:
dependencies:
path_provider:
git:
url: "https://gitcode.com/openharmony-sig/flutter_packages.git"
path: "packages/path_provider/path_provider"
以shared_preferences举例:
在引用的项目中,pubspec.yaml中dependencies新增配置:
dependency_overrides:
shared_preferences:
git:
url: "https://gitcode.com/openharmony-sig/flutter_packages.git"
path: "packages/shared_preferences/shared_preferences"
以url_launcher举例:
在引用的项目中,pubspec.yaml中dependencies新增配置:
dependency_overrides:
url_launcher:
git:
url: "https://gitcode.com/openharmony-sig/flutter_packages.git"
path: "packages/url_launcher/url_launcher"
以flutter_phone_direct_caller举例:
在引用的项目中,pubspec.yaml中dependencies新增配置:
dependency_overrides:
flutter_phone_direct_caller:
git:
url: "https://gitcode.com/openharmony-sig/fluttertpc_flutter_phone_direct_caller.git"
大致就是这样,如何想要查看那个库是否适配,
https://gitcode.com/openharmony-sig/flutter_packages
Flutter/Dart生态中,库可以分为纯Dart库和平台相关库。判断一个库是否为纯Dart库的方法有:
欢迎大家持续关注坚果派。