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

babel-plugin-transform-builtin-extend

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-transform-builtin-extend - npm Package Compare versions

Comparing version 1.0.0 to 1.1.0

4

lib/index.js

@@ -54,3 +54,3 @@ 'use strict';

*/
var buildHelper = (0, _babelTemplate2.default)('\n function HELPER(cls){\n function ExtendableBuiltin(){\n var instance = cls.apply(this, arguments) || this;\n Object.setPrototypeOf(instance, Object.getPrototypeOf(this));\n return instance;\n }\n ExtendableBuiltin.prototype = Object.create(cls.prototype, {\n constructor: {\n value: cls,\n enumerable: false,\n writable: true,\n configurable: true,\n }\n });\n if (Object.setPrototypeOf){\n Object.setPrototypeOf(ExtendableBuiltin, cls);\n } else {\n ExtendableBuiltin.__proto__ = cls;\n }\n\n return ExtendableBuiltin;\n }\n');
var buildHelper = (0, _babelTemplate2.default)('\n function HELPER(cls){\n function ExtendableBuiltin(){\n // Not passing "newTarget" because core-js would fall back to non-exotic\n // object creation.\n var instance = Reflect.construct(cls, Array.from(arguments));\n Object.setPrototypeOf(instance, Object.getPrototypeOf(this));\n return instance;\n }\n ExtendableBuiltin.prototype = Object.create(cls.prototype, {\n constructor: {\n value: cls,\n enumerable: false,\n writable: true,\n configurable: true,\n },\n });\n if (Object.setPrototypeOf){\n Object.setPrototypeOf(ExtendableBuiltin, cls);\n } else {\n ExtendableBuiltin.__proto__ = cls;\n }\n\n return ExtendableBuiltin;\n }\n');

@@ -63,2 +63,2 @@ /**

*/
var buildHelperApproximate = (0, _babelTemplate2.default)('\n function HELPER(cls){\n function ExtendableBuiltin(){\n cls.apply(this, arguments);\n }\n ExtendableBuiltin.prototype = Object.create(cls.prototype, {\n constructor: {\n value: cls,\n enumerable: false,\n writable: true,\n configurable: true,\n }\n });\n if (Object.setPrototypeOf){\n Object.setPrototypeOf(ExtendableBuiltin, cls);\n } else {\n ExtendableBuiltin.__proto__ = cls;\n }\n\n return ExtendableBuiltin;\n }\n');
var buildHelperApproximate = (0, _babelTemplate2.default)('\n function HELPER(cls){\n function ExtendableBuiltin(){\n cls.apply(this, arguments);\n }\n ExtendableBuiltin.prototype = Object.create(cls.prototype, {\n constructor: {\n value: cls,\n enumerable: false,\n writable: true,\n configurable: true,\n },\n });\n if (Object.setPrototypeOf){\n Object.setPrototypeOf(ExtendableBuiltin, cls);\n } else {\n ExtendableBuiltin.__proto__ = cls;\n }\n\n return ExtendableBuiltin;\n }\n');
{
"name": "babel-plugin-transform-builtin-extend",
"description": "A plugin for Babel 6 supports extending from builtin types based on static analysis.",
"version": "1.0.0",
"version": "1.1.0",
"author": "Logan Smyth <loganfsmyth@gmail.com>",

@@ -6,0 +6,0 @@ "main": "lib",

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