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

Prevent output of .js files when using images as entry points #4

Open
OzymandiasTheGreat opened this issue Jun 28, 2019 · 3 comments
Open

Comments

@OzymandiasTheGreat
Copy link

I'm using a custom plugin to glob most of my source tree as input.
Problem is, when specifying non-javascript file as entry point, rollup still generates a bundle for it (often empty, depends on plugins).
Anyway even if this plugin didn't emit javascript code, there'd still be empty bundles.
So I propose a solution: detect when images are used as entry points and clean up auto generated javascript files at generateBundle event.
I got a working solution, if you think this could be useful, I'll make a pull request.

@malchata
Copy link
Owner

malchata commented Mar 2, 2021

Sorry for the late reply on this. If you still have a PR, I'd be open to it! I've been trying to do some much-needed housekeeping on my repos as of late.

@OzymandiasTheGreat
Copy link
Author

I'm sorry, I haven't used rollup in a while and I have pretty much no recollection of the code involved so making a PR at this point is not possible.

@malchata
Copy link
Owner

malchata commented Mar 3, 2021

No worries. I let this languish for a while anyway, but based on your initial issue, I think I have a way to get this done. Thanks!

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