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

@lwc/metadata

Package Overview
Dependencies
Maintainers
0
Versions
128
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@lwc/metadata - npm Package Compare versions

Comparing version 9.5.0 to 10.0.0-canary.9d570

dist/__tests__/bundle-metadata.spec.d.ts

2

dist/bundle-metadata.js

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

} */
const version = '9.5.0';
const version = '10.0.0-canary.9d570';
function collectBundleMetadata(config) {

@@ -81,0 +81,0 @@ // validateBundleConfig(config);

@@ -0,1 +1,2 @@

import { ImportDeclaration } from '@babel/types';
import { ScriptFileType } from '../../script-metadata/utils';

@@ -147,2 +148,3 @@ import { File, SourceLocation } from './common-metadata-types';

namespaceImport?: NamespaceImport;
importKind?: ImportDeclaration['importKind'];
moduleSpecifier: string;

@@ -159,2 +161,3 @@ location: SourceLocation;

aliasName?: string;
importKind?: ImportDeclaration['importKind'];
location: SourceLocation;

@@ -161,0 +164,0 @@ }

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

function gatherImportMetadata(node, result, refId) {
const { source: { value: moduleSpecifier }, specifiers, } = node;
const { source: { value: moduleSpecifier }, specifiers, importKind, } = node;
const importMetadata = {

@@ -21,2 +21,6 @@ moduleSpecifier,

};
// add import kind for type imports in TypeScript files
if (importKind) {
importMetadata.importKind = importKind;
}
const namedImports = [];

@@ -42,9 +46,13 @@ specifiers.forEach((specifier) => {

case 'ImportSpecifier': {
const { imported } = specifier;
const { imported, importKind } = specifier;
const importedName = resolver.resolveImportSpecifierImported(imported);
namedImports.push({
const namedImport = {
name: importedName,
aliasName: local.name === importedName ? undefined : local.name,
location,
});
};
if (importKind) {
namedImport.importKind = importKind;
}
namedImports.push(namedImport);
break;

@@ -51,0 +59,0 @@ }

{
"name": "@lwc/metadata",
"version": "9.5.0",
"version": "10.0.0-canary.9d570",
"description": "Extract metadata about Lightning Web Components modules. This software is provided as-is with no support provided.",

@@ -20,3 +20,3 @@ "main": "dist/index.js",

"@babel/types": "~7.24.8",
"@lwc/sfdc-compiler-utils": "9.5.0",
"@lwc/sfdc-compiler-utils": "10.0.0-canary.9d570",
"postcss": "~8.4.39",

@@ -36,3 +36,4 @@ "postcss-selector-parser": "~6.1.0",

"node": ">=14"
}
},
"gitHead": "13df46dd4cdda16cf832962cbe9d1342b48ae561"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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