plasticine / inject-loader

💉📦 A Webpack loader for injecting code into modules via their dependencies.
https://www.npmjs.com/package/inject-loader
MIT License
484 stars 47 forks source link

Should emit an error if when an injection is set via query and then not used #2

Closed plasticine closed 8 years ago

plasticine commented 9 years ago

Given:

var MyStoreProxy = require('inject?lib/dispatcher!stores/my_store')

Should raise an error:

var Dispatcher = MyStoreProxy()

Shouldn’t error:

var StubDispatcher = {};
var MyStore = MyStoreProxy({'lib/dispatcher': StubDispatcher})