• This project
    • Loading...
  • Sign in

flutter_package / fluttertpc_get

Go to a project
Toggle navigation
  • Projects
  • Groups
  • Snippets
  • Help
Toggle navigation pinning
  • Project
  • Activity
  • Repository
  • Pipelines
  • Graphs
  • Issues 0
  • Merge Requests 0
  • Wiki
  • Network
  • Create a new issue
  • Builds
  • Commits
  • Files
  • Commits
  • Network
  • Compare
  • Branches
  • Tags
Switch branch/tag
  • fluttertpc_get
  • lib
  • _provider
  • _state.dart
  • Added Benchmarks · 98a36e4b
    98a36e4b Browse Files
    Jonny Borges authored 2020-06-10 15:10:03 -0300
_state.dart 269 Bytes
Raw Blame History Permalink
1 2 3 4 5 6 7 8 9 10 11 12 13 14
import 'package:flutter/foundation.dart';
import 'package:benckmark/item.dart';

class AppState with ChangeNotifier {
  List<Item> _items = sampleItems;

  List<Item> get items => _items;

  void addItem(Item item) {
    _items.add(item);

    notifyListeners();
  }
}