Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unresolved integrity placeholders #230

Open
combmag opened this issue Jan 23, 2024 · 2 comments
Open

Unresolved integrity placeholders #230

combmag opened this issue Jan 23, 2024 · 2 comments

Comments

@combmag
Copy link

combmag commented Jan 23, 2024

Hi,

I am trying to implement this webpack plugin for our nx angular app. I added a new webpack.config.json as seen below

const ModuleFederationPlugin = require('webpack/lib/container/ModuleFederationPlugin');
const { SubresourceIntegrityPlugin } = require('webpack-subresource-integrity');
const {
    shareAll,
    } = require('@angular-architects/module-federation/webpack');
	
module.exports = {
	output: {
		publicPath: 'auto',
		uniqueName: 'angular3',
		scriptType: 'text/javascript',
		crossOriginLoading: "anonymous"
	},
	stats: "detailed",
	optimization: {
		runtimeChunk: false,
	},
	plugins: [
		new ModuleFederationPlugin({
			// For remotes (please adjust)
			name: 'angular3',
			library: { type: 'var', name: 'angular3' },
			filename: 'remoteEntry.js',
			exposes: {
				'./webcomponents': 'apps/site/src/bootstrap.ts',
			},

			// For hosts (please adjust)
			/*
      remotes: {
          'mfe1': "mfe1@http://localhost:3000/remoteEntry.js" 
      },
      */

			shared: {
				...shareAll({
					singleton: true,
					strictVersion: true,
					requiredVersion: 'auto',
				}),
			},
		}),
		new SubresourceIntegrityPlugin({
			hashFuncNames: ['sha256', 'sha384'],
			enabled: true,
		}),
	],
};

But i am getting
Error: webpack-subresource-integrity: Asset main.4eabbc3c8909fb56.js contains unresolved integrity placeholders without any info it's making it really hard to debug.

@coharishkumarreddy
Copy link

I am also facing same issue, Any update on this?

@maodelife
Copy link

i am facing too. and it is few info to debug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants