Split amf.js into constituent components