statics

static assets in npm


Keywords
statics, react, npm, static, assets, packaging
License
Apache-2.0
Install
npm install statics@0.1.0

Documentation

statics

unmaintained

Warning: codebase going through major changes.

Mission

Package static assets in npm. Support client and server.

API for component authors

  • process.env.STATIC_ROOT: this is where your static files will live at runtime
  • staticRoot in package.json: this is where you put your static files. they'll be available at the root above

API for users

  • run collect-static mymodule builddir/ and upload builddir/ to http://mycdn.com/statics/
  • run your app with STATIC_ROOT=http://mycdn.com/statics/ (trailing slash required)
    • if using browserify, use the envify transform