Skip to content

Instantly share code, notes, and snippets.

@nestorsgarzonc
Created September 9, 2021 13:03
Show Gist options
  • Select an option

  • Save nestorsgarzonc/b8e00e0216f3aeda546387a591b4bdc8 to your computer and use it in GitHub Desktop.

Select an option

Save nestorsgarzonc/b8e00e0216f3aeda546387a591b4bdc8 to your computer and use it in GitHub Desktop.
Flutter 2.5.0 scroll bug example
import 'package:flutter/material.dart';
void main() => runApp(MyApp());
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Material App',
initialRoute: '/',
routes: {
'/': (ctx) => Body(),
},
);
}
}
class Body extends StatelessWidget {
const Body({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Scaffold(
body: ListView.separated(
itemCount: 100,
separatorBuilder: (context, index) => const Divider(),
itemBuilder: (context, index) => Container(
color: Colors.orange,
width: 100,
height: 100,
),
),
);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment