refactored into multiple files + docs
0.2.9