Implement #53. Various style improvements.
Update documentation.
Fix replaceAliases duplication bug
Add missing links to readme