merging classes with ```joinClasses```
reference: https://gist.github.com/sebmarkbage/a6e220b7097eb3c79ab7