smart_assets_plugin 1.0.0
smart_assets_plugin: ^1.0.0 copied to clipboard
智能资源下载插件 - 支持图片压缩、远端下载、智能切换的 Flutter 资源优化方案
Use this package as an executable
Install it
You can install the package from the command line:
dart pub global activate smart_assets_pluginUse it
The package has the following executables:
$ build_all
$ compress_assets
$ generate_constants
$ generate_manifest
$ generate_zip
$ init_config
$ replace_image_usage
$ restore_assets
Use this package as a library
Depend on it
Run this command:
With Flutter:
$ flutter pub add smart_assets_pluginThis will add a line like this to your package's pubspec.yaml (and run an implicit flutter pub get):
dependencies:
smart_assets_plugin: ^1.0.0Alternatively, your editor might support flutter pub get. Check the docs for your editor to learn more.
Import it
Now in your Dart code, you can use:
import 'package:smart_assets_plugin/smart_assets_plugin.dart';