A flutter package to display a git graph chart 🌊
MIT License
A Flutter library to easily visualize shiny Git Graphs.
Add as a dependency
dependencies:
flutter_gitgraph: latest_version
Declare a list of commits
const COMMIT_DATA = [
{'id': 'cmt_1', 'name': 'h45edf'},
{'id': 'cmt_2', 'name': 'ed3sdf', 'prev': 'cmt_1'},
{'id': 'cmt_3', 'name': 'asd32n', 'prev': 'cmt_2'},
{'id': 'cmt_4', 'name': 'bsh32j', 'prev': 'cmt_3'},
{'id': 'cmt_5', 'name': 'f3h3dr', 'prev': 'cmt_2'},
{'id': 'cmt_6', 'name': 'jf3djs', 'prev': 'cmt_3'},
{'id': 'cmt_7', 'name': 'z45dsw', 'prev': 'cmt_3'},
{'id': 'cmt_8', 'name': 'djw4ls', 'prev': 'cmt_6'},
{'id': 'cmt_9', 'name': '3edfk3', 'prev': 'cmt_4'},
{'id': 'cmt_10', 'name': 'fdhj3fg', 'prev': 'cmt_4'},
{'id': 'cmt_11', 'name': 'dk32fhj', 'prev': 'cmt_5'},
{'id': 'cmt_12', 'name': 'dhj45kv', 'prev': 'cmt_1'}
];
Add it to a List
List<Commit> commits = [];
Pass it as a parameter to the widget
body: Center(
child: GitGraph(commits: commits),
),
Setting things up:
git clone [email protected]:Sameerkash/flutter_gitgraph.git
flutter channel
flutter channel dev
flutter upgrade
Read our contributing guide to learn about our development process, how to propose bugfixes and improvements.
To help you get your feet wet and get you familiar with our contribution process, we have a list of good first issues that contain bugs/features which have a relatively limited scope. This is a great place to get started.
Copyright (c) 2021 Sameer Kashyap under the MIT license.
Inspired by GitGraph.js