webamp/examples/webpackLazyLoad
Jordan Eldredge b3a17c8f99 Release 1.4.0
2019-05-14 08:04:54 -07:00
..
index.html Center Webamp vertically in example sites 2019-05-09 06:47:20 -07:00
index.js Webpack example with lazy loading butterchurn and presets 2019-03-19 08:36:59 -07:00
package.json Release 1.4.0 2019-05-14 08:04:54 -07:00
README.md README tweaks 2019-03-19 08:36:59 -07:00

Minimal Lazy Loading Example

API is still being finalized and may change when released

This example includes Webamp in a Webpack bundle. The audio file and skin are fetched from a free CDN at run time. Milkdrop and visualizer presets are lazy loaded after playing starts.

Note: Currently Webamp is published to NPM as a single bundle which includes all of its dependencies. This means that no matter what you do, Webamp is going to bring along it's own React, Redux, JSZip, etc. If you have a use case where you would like Webamp to share some or all of these dependencies with your own application, please file an issue and I can look into it.

To try it out:

$ git clone git@github.com:captbaritone/webamp.git
$ cd webamp/examples/webpackLazyLoad/
$ npm install
$ npm run build
$ open index.html