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

@backbase/generator-ext-ng

Package Overview
Dependencies
Maintainers
2
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@backbase/generator-ext-ng - npm Package Compare versions

Comparing version 2.0.3 to 2.0.4

36

default/index.js

@@ -0,15 +1,29 @@

const nameConventionRegex = /^ext-([^\-]+)-(.*?)(?:-(ng))?$/;
const prompts = (api, presets) => {
const description = Object.assign({}, presets.description, {
default: function(answers) {
return answers.name.replace(/ext-bb-(.+?)(?:-ng|$)/, function(a, b) {
return b ? 'Default extension for widget-bb-' + b + '-ng' : answers.name;
});
}
default: answers => answers.name.replace(
/ext-bb-(.+?)(?:-ng|$)/,
(a, b) => (b ? `Default extension for widget-bb-${b}-ng` : answers.name)
),
});
const controllerName = (name) => {
const baseName = nameConventionRegex.test(name)
? name.match(nameConventionRegex)[2]
: name;
return `${api.filter.upperFirst(api.filter.camelCase(baseName))}Controller`;
};
const controller = {
name: 'controller',
message: 'Widget Controller',
default: answers => controllerName(answers.name),
};
return [
presets.name,
description,
presets.version
controller,
presets.version,
];

@@ -20,7 +34,5 @@ };

module.exports = function(api, presets) {
return api(
prompts(api, presets),
config
);
};
module.exports = (api, presets) => api(
prompts(api, presets),
config
);

@@ -7,1 +7,5 @@ // uncomment below to include CSS in your extension

export const hooks = {};
export const helpers = {};
export const events = {};
{
"name": "@backbase/generator-ext-ng",
"version": "2.0.3",
"version": "2.0.4",
"description": "Generate angular widget extension feature",

@@ -5,0 +5,0 @@ "main": "default/index.js",

Sorry, the diff of this file is not supported yet

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