native_image_view 0.0.2 icon indicating copy to clipboard operation
native_image_view: ^0.0.2 copied to clipboard

该组件提供了一种方式,可以让flutter通过methodChannel调用原生的本地和网络图片的加载

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:native_image_view/native_image_view.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatefulWidget {
  @override
  _MyAppState createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  String url = "https://iknow-pic.cdn.bcebos.com/79f0f736afc379313a380ef3e7c4b74542a91193";
  //String url = "localImage://wdqy.jpeg";

  @override
  void initState() {
    super.initState();
  }

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(
          title: Text('example'),
        ),
        body: Center(
        child: NativeImageView(
          url: url,
          width: 300,
          height: 200,
        ),
      ),
    ));
  }
}
1
likes
85
pub points
0%
popularity

Publisher

unverified uploader

该组件提供了一种方式,可以让flutter通过methodChannel调用原生的本地和网络图片的加载

Repository (GitHub)

Documentation

API reference

License

Icon for licenses.MIT (LICENSE)

Dependencies

flutter

More

Packages that depend on native_image_view