var add = function() { alert('Buy a cat'); }
var remove = function() { alert('Give a cat'); }
undone.execute(add, remove); // Alerts 'Buy a cat'
undone.undo(); // Alerts 'Give a cat'
undone.redo(); // Alerts 'Buy a cat'
See the complete documentation in undone.js
To install for a website, copy undone.min.js
with the other javascript files of your project and include it.
To install in a Node.js project npm install undone
Give what you want to contribute to open-source :
You can create issues.
You can also contribute code :
- Fork the code on GitHub
- Clone your fork in your environment :
git clone git@github.com:USERNAME/undone.git
- Create a branch for your feature :
git checkout -b your_branch_name
- Write and delete code and commit as often as you can :
git commit -am "A descriptive message"
- Push the branch to your fork :
git push origin your_branch_name
- Create a pull request on GitHub (click the Pull request button on your fork page)
- Create an issue.
- Write me an email at dsimard@azanka.ca