We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
In order to better support Import Attributes, we need to support attributes in NormalModuleFactory resolve hook.
attributes
export type ResolveData = { contextInfo: ContextInfo; context: string; request: string; + attributes?: Record<string, any>; fileDependencies: string[]; missingDependencies: string[]; contextDependencies: string[]; createData?: CreateData; };
By the way, this feature is already supported in webpack, but the key name is assertions.
assertions
https://github.com/webpack/webpack/blob/5e09d0e05f243d8d2c14c9fe140eba32b7aaeac7/types.d.ts#L12442
compiler.hooks.compilation.tap( 'MyPlugin', (compilation, { normalModuleFactory }) => { normalModuleFactory.hooks.resolve.tap('MyPlugin', resolveData => { + console.log(resolveData.attributes); }); }, );
The text was updated successfully, but these errors were encountered:
No branches or pull requests
What problem does this feature solve?
In order to better support Import Attributes, we need to support
attributes
in NormalModuleFactory resolve hook.export type ResolveData = { contextInfo: ContextInfo; context: string; request: string; + attributes?: Record<string, any>; fileDependencies: string[]; missingDependencies: string[]; contextDependencies: string[]; createData?: CreateData; };
By the way, this feature is already supported in webpack, but the key name is
assertions
.https://github.com/webpack/webpack/blob/5e09d0e05f243d8d2c14c9fe140eba32b7aaeac7/types.d.ts#L12442
What does the proposed API of configuration look like?
compiler.hooks.compilation.tap( 'MyPlugin', (compilation, { normalModuleFactory }) => { normalModuleFactory.hooks.resolve.tap('MyPlugin', resolveData => { + console.log(resolveData.attributes); }); }, );
The text was updated successfully, but these errors were encountered: