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

single-spa-angular

Package Overview
Dependencies
Maintainers
14
Versions
87
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

single-spa-angular - npm Package Compare versions

Comparing version 9.0.0 to 9.0.1-alpha

32

lib/webpack/index.js

@@ -11,3 +11,3 @@ "use strict";

exports.default = (config, options, extraOptions) => {
var _a, _b, _c, _d;
var _a, _b, _c, _d, _e;
const libraryName = getLibraryName(config, options);

@@ -62,2 +62,32 @@ extraOptions = Object.assign(Object.assign({}, defaultExtraOptions), extraOptions);

}
else {
// The `entry` doesn't have a `styles` property, which means we're on the Angular
// 15+ version where `StylesWebpackPlugin` was introduced to resolve module resolution
// issues related to Yarn PNP.
const stylesWebpackPluginName = 'StylesWebpackPlugin';
const stylesWebpackPlugin = mergedConfig.plugins.find((plugin) => plugin.constructor.name === stylesWebpackPluginName);
const entryPoints = (_e = stylesWebpackPlugin === null || stylesWebpackPlugin === void 0 ? void 0 : stylesWebpackPlugin.options) === null || _e === void 0 ? void 0 : _e.entryPoints;
if (entryPoints) {
// The `ngGlobalStyle` is a Webpack query required by Angular to
// apply a specific list of Webpack loaders to these files. There
// are only two queries available: `ngGlobalStyle` and `ngResource`
// (used for component styles).
// Webpack would then do the following:
// `{ use: globalStyleLoaders, resourceQuery: /\?ngGlobalStyle/ }`
const query = `?ngGlobalStyle`;
Object.keys(entryPoints).forEach(entryPoint => {
// `styles` is the primary styles that must be loaded with the main entry point.
if (entryPoint === 'styles') {
const styles = entryPoints.styles.map(path => `${path}${query}`);
mergedConfig.entry.main = [...styles, ...mergedConfig.entry.main];
}
else {
// Other entry points (which are lazy bundles) must be a part of entries to resolve
// to separate JS files.
mergedConfig.entry[entryPoint] = entryPoints[entryPoint].map(path => `${path}${query}`);
}
});
removePluginByName(mergedConfig.plugins, stylesWebpackPluginName);
}
}
// Remove bundles

@@ -64,0 +94,0 @@ // Since Angular 8 supports differential loading it also

2

package.json
{
"$schema": "../node_modules/ng-packagr/ng-package.schema.json",
"name": "single-spa-angular",
"version": "9.0.0",
"version": "9.0.1-alpha",
"description": "Helpers for building single-spa applications which use Angular 2",

@@ -6,0 +6,0 @@ "schematics": "./schematics/schematics.json",

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