Adapter that is similar to the ObjectAdapter (ArrayObjectAdapter) from the Android Leanback support library.

Example Project

There is a pretty sweet example project in the example folder. Check it out. Otherwise, keep reading to get up and running.


An array-based data source that provides access to a data model and is decoupled from the presentation of the items via Presenter/PresenterSelector. As the adapter implements the dart stream interface, you can simply observe the data set.

adapter.listen((_) { 
    // data set changed

  Widget build(BuildContext context) {
    return StreamBuilder(
      stream: _adapter,
      builder: (context, snapshot) {},);


Split presenter logic from adapter logic. Presenter that will create Views/Widgets and bind object.

/// A simple example where a string is represented as a text widget.
/// But imagine for example a user object, which is represented with a thumbnail, name and address etc.
class TextPresenter extends Presenter {
  Widget createView(BuildContext context, Object item) {
    final value = item as String;
    return Text(value);

To use multiple viewTypes use PresenterSelector.

final classPresenterSelector = ClassPresenterSelector()
      ..addClassPresenter(int, IntPresenter())
      ..addClassPresenter(String, TextPresenter());

final adapter = ArrayObjectAdapter(presenterSelector: classPresenterSelector);

final items = <dynamic>[];
// create your content


Attach an adapter for the data to displayed to your view

  Widget build(BuildContext context) {
    return ListView.separated(
      itemCount: adapter.itemCount(),
      itemBuilder: (BuildContext context, int index) {
        final item = adapter.get(index);
        final presenter = adapter.getPresenter(item);
        return presenter.createView(context, item);
      separatorBuilder: (BuildContext context, int index) => Divider(),