require-noop
v0.0.2
Published
transform required files with given extensions in noops
Downloads
3
Readme
require-noop
Inhibits require
on selected extensions.
Useful in isomorphic setups, where - for instance - we want require('asset.png')
to use a webpack loader on the client, but result in a noop on the server.
Installation
npm install require-noop
Usage
require('require-noop')({
extensions: ['.png']
});