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

electrum-require-components

Package Overview
Dependencies
Maintainers
3
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

electrum-require-components - npm Package Compare versions

Comparing version 1.7.3 to 1.8.0

bin/electrum-require-components

4

lib/main.js

@@ -37,5 +37,5 @@ 'use strict';

if (more.length === 0) {
return `Electrum.wrap ('${ name }', _${ name })`;
return `Electrum.wrap ('${name}', _${name})`;
} else {
return `Electrum.wrap ('${ name }', _${ name }, {${ more.map(x => `${ x }: _${ name }$${ x }`).join(', ') }})`;
return `Electrum.wrap ('${name}', _${name}, {${more.map(x => `${x}: _${name}$${x}`).join(', ')}})`;
}

@@ -42,0 +42,0 @@ }

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

for (let file of files) {
const regex = new RegExp(`${ name }\\.([a-zA-Z]+)\\.js`);
const regex = new RegExp(`${name}\\.([a-zA-Z]+)\\.js`);
const match = file.match(regex);

@@ -26,0 +26,0 @@ if (match) {

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

function getImport(name, filePath) {
return `import _${ upper(name) } from './${ filePath }';`;
return `import _${upper(name)} from './${filePath}';`;
}

@@ -33,3 +33,3 @@

for (let suffix of suffixes) {
list.push(getImport(`${ upper(name) }$${ suffix }`, `${ dirPath }/${ name }.${ suffix }.js`));
list.push(getImport(`${upper(name)}$${suffix}`, `${dirPath}/${name}.${suffix}.js`));
}

@@ -43,5 +43,5 @@ return list;

const more = suffixes;
return `export const ${ Name } = ${ inject(Name, filePath, more) };`;
return `export const ${Name} = ${inject(Name, filePath, more)};`;
} else {
return `export const ${ Name } = _${ Name };`;
return `export const ${Name} = _${Name};`;
}

@@ -48,0 +48,0 @@ }

{
"name": "electrum-require-components",
"version": "1.7.3",
"version": "1.8.0",
"description": "This Electrum build tool generates a source file with a list of requires.",
"main": "lib/index.js",
"bin": {
"electrum-require-components": "./bin/bin.js"
"electrum-require-components": "./bin/electrum-require-components"
},

@@ -9,0 +9,0 @@ "scripts": {

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