{"library":"shebang-loader","title":"shebang-loader","description":"Webpack loader that strips the shebang (#!) line from script files, allowing them to be bundled as modules. Current version 0.0.1 is a minimal, unmaintained package with no releases since 2014. It only works with webpack 1.x and provides no configuration options. Not suitable for modern projects; alternatives include inline loader syntax or manual file transforms.","language":"javascript","status":"deprecated","last_verified":"Sat Apr 25","install":{"commands":["npm install shebang-loader"],"cli":null},"imports":["import script from 'shebang-loader!./file.js';","module.exports = { module: { rules: [ { test: /\\.js$/, use: 'shebang-loader' } ] } }","var script = require('shebang-loader!./file.js');"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"// webpack.config.js\nmodule.exports = {\n  module: {\n    rules: [\n      {\n        test: /\\.js$/,\n        use: 'shebang-loader'\n      }\n    ]\n  }\n};\n\n// Now require a CLI script with a shebang line\n// bin/hello.js: #!/usr/bin/env node\\nconsole.log('Hello');\nconst hello = require('shebang-loader!./bin/hello.js');\nconsole.log(hello); // 'Hello'","lang":"javascript","description":"Webpack config to strip shebang from .js files and an example requiring a CLI script.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}