Jstd new bundler support

- changing JSTD to use the new model for js bundles
- code isn't the best code i've written, but since we're tearing out the JSTD suff eventually we can afford a quick (and slightly hacky) implementation
- tests for apps will work, but tests for SDK libs will fail until we can restructure the libs
- js tests current fail and need to be investigated - but some nodejs style classes are included