refactored demos to use requirejs when needed, added demo for some basic js examples