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

@module-federation/managers

Package Overview
Dependencies
Maintainers
8
Versions
507
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@module-federation/managers - npm Package Compare versions

Comparing version 0.0.0-next-20240227133524 to 0.0.0-next-20240227135200

43

dist/index.cjs.js

@@ -398,2 +398,3 @@ 'use strict';

_define_property$3(_assert_this_initialized$2(_this), "_manifestModuleInfos", void 0);
_define_property$3(_assert_this_initialized$2(_this), "_parsedOptions", void 0);
return _this;

@@ -480,9 +481,6 @@ }

var parsedOptions = this._parseOptions();
return Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
var parsedOption = parsedOptions[exposeKey];
return parsedOptions.reduce(function(sum, item) {
var _item = _sliced_to_array$1(item, 2), exposeKey = _item[0], exposeObject = _item[1];
sum[exposeKey] = [];
var importArr = Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
];
importArr.forEach(function(item) {
exposeObject.import.forEach(function(item) {
var relativePath = path__default["default"].relative(".", item.replace(path__default["default"].extname(item), ""));

@@ -500,9 +498,6 @@ sum[exposeKey].push(relativePath);

var parsedOptions = this._parseOptions();
return Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
return parsedOptions.reduce(function(sum, item) {
var _sum;
var parsedOption = parsedOptions[exposeKey];
var importArr = Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
];
(_sum = sum).push.apply(_sum, _to_consumable_array(importArr));
var _item = _sliced_to_array$1(item, 2); _item[0]; var exposeObject = _item[1];
(_sum = sum).push.apply(_sum, _to_consumable_array(exposeObject.import));
return sum;

@@ -520,9 +515,7 @@ }, []);

var parsedOptions = this._parseOptions();
this._manifestModuleInfos = Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
var parsedOption = parsedOptions[exposeKey];
this._manifestModuleInfos = parsedOptions.reduce(function(sum, item) {
var _item = _sliced_to_array$1(item, 2), exposeKey = _item[0], exposeObject = _item[1];
sum[exposeKey] = {
name: parsedOption.name || normalizeExposeModuleName(exposeKey),
file: Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
]
name: exposeObject.name || normalizeExposeModuleName(exposeKey),
file: exposeObject.import
};

@@ -548,5 +541,10 @@ return sum;

value: function _parseOptions() {
return parseOptions(this.options.exposes, function(item) {
if (this._parsedOptions) {
return this._parsedOptions;
}
this._parsedOptions = parseOptions(this.options.exposes, function(item) {
return {
import: item,
import: Array.isArray(item) ? item : [
item
],
name: undefined

@@ -556,6 +554,9 @@ };

return {
import: item.import,
import: Array.isArray(item.import) ? item.import : [
item.import
],
name: undefined
};
});
return this._parsedOptions;
}

@@ -562,0 +563,0 @@ },

@@ -387,2 +387,3 @@ import path from 'path';

_define_property$3(_assert_this_initialized$2(_this), "_manifestModuleInfos", void 0);
_define_property$3(_assert_this_initialized$2(_this), "_parsedOptions", void 0);
return _this;

@@ -469,9 +470,6 @@ }

var parsedOptions = this._parseOptions();
return Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
var parsedOption = parsedOptions[exposeKey];
return parsedOptions.reduce(function(sum, item) {
var _item = _sliced_to_array$1(item, 2), exposeKey = _item[0], exposeObject = _item[1];
sum[exposeKey] = [];
var importArr = Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
];
importArr.forEach(function(item) {
exposeObject.import.forEach(function(item) {
var relativePath = path.relative(".", item.replace(path.extname(item), ""));

@@ -489,9 +487,6 @@ sum[exposeKey].push(relativePath);

var parsedOptions = this._parseOptions();
return Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
return parsedOptions.reduce(function(sum, item) {
var _sum;
var parsedOption = parsedOptions[exposeKey];
var importArr = Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
];
(_sum = sum).push.apply(_sum, _to_consumable_array(importArr));
var _item = _sliced_to_array$1(item, 2); _item[0]; var exposeObject = _item[1];
(_sum = sum).push.apply(_sum, _to_consumable_array(exposeObject.import));
return sum;

@@ -509,9 +504,7 @@ }, []);

var parsedOptions = this._parseOptions();
this._manifestModuleInfos = Object.keys(parsedOptions).reduce(function(sum, exposeKey) {
var parsedOption = parsedOptions[exposeKey];
this._manifestModuleInfos = parsedOptions.reduce(function(sum, item) {
var _item = _sliced_to_array$1(item, 2), exposeKey = _item[0], exposeObject = _item[1];
sum[exposeKey] = {
name: parsedOption.name || normalizeExposeModuleName(exposeKey),
file: Array.isArray(parsedOption.import) ? parsedOption.import : [
parsedOption.import
]
name: exposeObject.name || normalizeExposeModuleName(exposeKey),
file: exposeObject.import
};

@@ -537,5 +530,10 @@ return sum;

value: function _parseOptions() {
return parseOptions(this.options.exposes, function(item) {
if (this._parsedOptions) {
return this._parsedOptions;
}
this._parsedOptions = parseOptions(this.options.exposes, function(item) {
return {
import: item,
import: Array.isArray(item) ? item : [
item
],
name: undefined

@@ -545,6 +543,9 @@ };

return {
import: item.import,
import: Array.isArray(item.import) ? item.import : [
item.import
],
name: undefined
};
});
return this._parsedOptions;
}

@@ -551,0 +552,0 @@ },

@@ -6,2 +6,3 @@ import type { containerPlugin, ManifestModuleInfos, moduleFederationPlugin } from '@module-federation/sdk';

private _manifestModuleInfos?;
private _parsedOptions?;
get enable(): boolean;

@@ -8,0 +9,0 @@ get globalEntryName(): string | undefined;

{
"name": "@module-federation/managers",
"version": "0.0.0-next-20240227133524",
"version": "0.0.0-next-20240227135200",
"license": "MIT",

@@ -24,3 +24,3 @@ "description": "Provide managers for helping handle mf data .",

"fs-extra": "9.1.0",
"@module-federation/sdk": "0.0.0-next-20240227133524"
"@module-federation/sdk": "0.0.0-next-20240227135200"
},

@@ -27,0 +27,0 @@ "devDependencies": {

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