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

Adding assets in compiler.plugin('emit') state - not appearing in manifest #5

Open
lgordey opened this issue Jul 22, 2015 · 7 comments

Comments

@lgordey
Copy link

lgordey commented Jul 22, 2015

Hi @nickjj

I solved some problems with plugin, but it already didn't appearing in manifest.json.

You can see it here - https://github.com/lgordey/webpack-plugin.

I think problem is in Compilation instance of webpack, but maybe you know why thats not working.

Thanks!

@lgordey
Copy link
Author

lgordey commented Jul 22, 2015

I think the reason is because you taking assets from data.modules and not from data.assets.
So added assets from other plugins in this case will not appear in manifest.json.

@lgordey
Copy link
Author

lgordey commented Jul 22, 2015

var data = stats.toJson(options);

data.assets :
image

data.modules:
image

Second screen is very big, but u can see, that there is no my-sprite in modules.name section

@nickjj
Copy link
Owner

nickjj commented Jul 22, 2015

I believe in the assets section, it included css and js files but the modules section omits them.

@lgordey
Copy link
Author

lgordey commented Jul 22, 2015

Modules section doesn't include dynamically added assets - that's the problem.

@lgordey
Copy link
Author

lgordey commented Jul 24, 2015

I think it is a webpack issue at first.

Cause in current situation we can't show in manifest assets that have been added from another plugins.

You can read linked issue.

@nickjj
Copy link
Owner

nickjj commented Jul 24, 2015

Thanks for putting so much time into this issue. I wonder what will come from it on the webpack side.

@lgordey
Copy link
Author

lgordey commented Jul 24, 2015

I created pull request (webpack/webpack#1291) to create field that contains path, so you can take assets from stats.assets, I hope it will be approved and merged.

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

2 participants