Socket
Socket
Sign inDemoInstall

requisite

Package Overview
Dependencies
316
Maintainers
1
Versions
201
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.18.0 to 1.18.1

9

lib/bundle.js

@@ -18,7 +18,7 @@ // Generated by CoffeeScript 1.10.0

return new Prelude({
async: opts.async,
bare: opts.bare,
globalRequire: opts.globalRequire,
prelude: opts.prelude,
preludeAsync: opts.preludeAsync
preludeAsync: opts.preludeAsync,
includeAsync: opts.includeAsync
});

@@ -61,3 +61,4 @@ };

exclude: exclude,
"export": opts["export"],
exported: opts.exported,
required: opts.required,
include: include,

@@ -84,3 +85,3 @@ moduleCache: opts.moduleCache,

if (v.async) {
opts.async = true;
opts.includeAsync = true;
break;

@@ -87,0 +88,0 @@ }

@@ -22,3 +22,3 @@ // Generated by CoffeeScript 1.10.0

help = function() {
console.log("\nUsage: requisite [options] [files]\n\nOptions:\n\n -h, --help display this help\n -v, --version display version\n -a, --async prelude should support async requires\n -b, --bare compile without a top-level function wrapper\n -d, --dedupe deduplicate modules (when multiple are specified)\n -e, --export <name> export module as <name>\n -i, --include <module:path> force inclusion of module found at path\n -g, --global global require\n -m, --minify minify output\n --minifier minifier to use\n -o, --output <file> write bundle to file instead of stdout, {} may be used as a placeholder\n -p, --prelude <file> file to use as prelude\n --no-prelude exclude prelude from bundle\n --source-map enable source maps\n --prelude-only only output prelude\n -r, --resolve <module:path> do not automatically resolve module, use provided path\n --require-as <path> resolve bundle using providing path\n -s, --strict add \"use strict\" to each bundled module\n --strip-debug strip `alert`, `console`, `debugger` statements\n -w, --watch write bundle to file and and recompile on file changes\n -x, --exclude <glob|regex> exclude modules matching glob or regex from being automatically parsed\n --base path all requires should be relative to\n\nExamples:\n\n # bundle javascript file and all it's dependencies\n $ requisite module.js -o bundle.js\n\n # bundle several modules, appending .bundle.js to output\n $ requisite *.js -o {}.bundle.js");
console.log("\nUsage: requisite [options] [files]\n\nOptions:\n\n -h, --help display this help\n -v, --version display version\n -a, --async bundle is expected to be required asynchronously\n -b, --bare compile without a top-level function wrapper\n -d, --dedupe deduplicate modules (when multiple are specified)\n -i, --include <module:path> force inclusion of module found at path\n -g, --global make prelude require global\n --export automatically export entry module as global\n --no-require do not automatically require entry module\n -m, --minify minify output\n --minifier minifier to use\n -o, --output <file> write bundle to file instead of stdout, {} may be used as a placeholder\n -p, --prelude <file> file to use as prelude\n --prelude-async include async prelude\n --prelude-only only output prelude\n --no-prelude exclude prelude from bundle\n -r, --resolve <module:path> do not automatically resolve module, use provided path\n --require-as <path> resolve bundle using providing path\n --source-map enable source maps\n -s, --strict add \"use strict\" to each bundled module\n --strip-debug strip `alert`, `console`, `debugger` statements\n -w, --watch write bundle to file and and recompile on file changes\n -x, --exclude <glob|regex> exclude modules matching glob or regex from being automatically parsed\n --base path all requires should be relative to\n\nExamples:\n\n # bundle javascript file and all it's dependencies\n $ requisite module.js -o bundle.js\n\n # bundle several modules, appending .bundle.js to output\n $ requisite *.js -o {}.bundle.js");
return process.exit(0);

@@ -38,3 +38,3 @@ };

exclude: [],
"export": null,
exported: null,
files: [],

@@ -45,2 +45,4 @@ include: {},

prelude: null,
preludeAsync: null,
required: false,
resolved: {},

@@ -85,5 +87,10 @@ sourceMap: false,

break;
case '-e':
case '--require':
opts.required = true;
break;
case '--no-require':
opts.required = false;
break;
case '--export':
opts["export"] = args.shift();
opts.exported = true;
break;

@@ -119,2 +126,6 @@ case '-i':

break;
case '--prelude-async':
case '--async-prelude':
opts.includeAsync = true;
break;
case '--prelude-only':

@@ -121,0 +132,0 @@ opts.preludeOnly = true;

@@ -74,4 +74,4 @@ // Generated by CoffeeScript 1.10.0

this.strict = opts.strict;
this["export"] = (ref6 = opts["export"]) != null ? ref6 : false;
this.require = (ref7 = opts.require) != null ? ref7 : true;
this.exported = (ref6 = opts.exported) != null ? ref6 : false;
this.required = (ref7 = opts.required) != null ? ref7 : true;
this.urlRoot = (ref8 = opts.urlRoot) != null ? ref8 : '';

@@ -437,4 +437,4 @@ this.ast = null;

if (!(this.async || this.bare)) {
if (this["export"]) {
ref3 = (parse("global." + this["export"] + " = require('" + this.requireAs + "');")).body;
if (this.exported) {
ref3 = (parse("global." + (path.basename(this.requireAs)) + " = require('" + this.requireAs + "');")).body;
for (j = 0, len1 = ref3.length; j < len1; j++) {

@@ -444,3 +444,3 @@ node = ref3[j];

}
} else if (this.require) {
} else if (this.required) {
ref4 = (parse("require('" + this.requireAs + "');")).body;

@@ -447,0 +447,0 @@ for (l = 0, len2 = ref4.length; l < len2; l++) {

@@ -48,7 +48,7 @@ // Generated by CoffeeScript 1.10.0

}
this.async = (ref = opts.async) != null ? ref : true;
this.bare = (ref1 = opts.bare) != null ? ref1 : false;
this.globalRequire = (ref2 = opts.globalRequire) != null ? ref2 : false;
this.prelude = (ref3 = opts.prelude) != null ? ref3 : path.join(__dirname, 'prelude.js');
this.preludeAsync = (ref4 = opts.preludeAsync) != null ? ref4 : path.join(__dirname, 'prelude-async.js');
this.bare = (ref = opts.bare) != null ? ref : false;
this.globalRequire = (ref1 = opts.globalRequire) != null ? ref1 : false;
this.prelude = (ref2 = opts.prelude) != null ? ref2 : path.join(__dirname, 'prelude.js');
this.preludeAsync = (ref3 = opts.preludeAsync) != null ? ref3 : path.join(__dirname, 'prelude-async.js');
this.includeAsync = (ref4 = opts.includeAsync) != null ? ref4 : false;
Prelude.__super__.constructor.call(this);

@@ -72,3 +72,3 @@ if (!this.bare) {

}
if (this.async) {
if (this.includeAsync) {
preludeAsync = parse(fs.readFileSync(this.preludeAsync));

@@ -82,3 +82,3 @@ ref6 = preludeAsync.body;

if (this.globalRequire) {
ref7 = (parse("global.require = require")).body;
ref7 = (parse('global.require = require')).body;
for (k = 0, len2 = ref7.length; k < len2; k++) {

@@ -85,0 +85,0 @@ node = ref7[k];

{
"name": "requisite",
"version": "1.18.0",
"version": "1.18.1",
"description": "A cosmic javascript bundler.",

@@ -5,0 +5,0 @@ "homepage": "http://requisitejs.org",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc