Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

require-from-string

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

require-from-string - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

license

6

index.js
'use strict';
var Module = module.constructor;
var path = require('path');

@@ -10,6 +11,7 @@ module.exports = function requireFromString(code, filename) {

var m = new Module();
m.paths = module.paths;
var m = new Module(filename, module);
m.filename = filename;
m.paths = Module._nodeModulePaths(path.dirname(filename));
m._compile(code, filename);
return m.exports;
};
{
"name": "require-from-string",
"version": "1.0.0",
"version": "1.0.1",
"description": "Require module from string",

@@ -5,0 +5,0 @@ "license": "MIT",

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc