reorderableitemsview 2.0.1 copy "reorderableitemsview: ^2.0.1" to clipboard
reorderableitemsview: ^2.0.1 copied to clipboard

A Flutter package for staggered grid view or ListView with ordering support

example/lib/main.dart

import 'package:flutter/material.dart';
import 'list_page.dart';
import 'grid_page.dart';

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

class MyApp extends StatelessWidget {
  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Reorderbale Items',
      theme: ThemeData(
        primarySwatch: Colors.blue,
        visualDensity: VisualDensity.adaptivePlatformDensity,
      ),
      home: MyHomePage(title: 'Reorderbale Items'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  MyHomePage({Key? key, this.title}) : super(key: key);
  final String? title;

  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title!),
      ),
      body: Column(
        children: <Widget>[
          RaisedButton(
            onPressed: () {
              Navigator.of(context).push(
                MaterialPageRoute(
                  builder: (context) => ListPageView()
                )
              );
            },
            child: Text(
              "ListView Demo"
            ),
          ),
          SizedBox(
            height: 16.0,
          ),
          RaisedButton(
            onPressed: () {
              Navigator.of(context).push(
                  MaterialPageRoute(
                      builder: (context) => GridPageView()
                  )
              );
            },
            child: Text(
                "Staggered Grid Demo"
            ),
          ),
        ],
      )
    );
  }
}
54
likes
80
pub points
82%
popularity

Publisher

verified publisherkarthikponnam.dev

A Flutter package for staggered grid view or ListView with ordering support

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter, flutter_staggered_grid_view

More

Packages that depend on reorderableitemsview