This code in question. Each item in the list is a Row with two Columns of text. Just this causes massive performance drops even in release mode. Currently trying to build a Reddit style layout for posts. Using Columns nested in a Row is drastically reducing performance. My guess is it's because Row's and Column's size themselves based on their children so nesting them increases the needed calculations for size. I just don't know how to work around this.
new ListView.builder(
controller: new ScrollController(initialScrollOffset: this.offset),
key: new UniqueKey(),
itemCount: this._posts != null ? this._posts.length : 0,
itemBuilder: (BuildContext context, int i) {
return new PostCard(
widget._posts[i],
);
},
),
The return of PostCard looks like this (example):
return new Container(
child: new Row(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
new Column(
children: <Widget>[
new Text("Hello World"),
new Text("Hello World"),
new Text("Hello World"),
new Text("Hello World"),
],
),
new Column(
children: <Widget>[
new Text("Hello World"),
new Text("Hello World"),
new Text("Hello World"),
new Text("Hello World"),
],
),
],
),
);
Edit: Screenshot of full UI sample. Same level of jank as the nested Column example above.