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

using image assets #71

Closed
AsaAyers opened this issue Jul 24, 2015 · 8 comments
Closed

using image assets #71

AsaAyers opened this issue Jul 24, 2015 · 8 comments

Comments

@AsaAyers
Copy link

How can I include assets that aren't JS or CSS?

It obviously requires a custom template, but somehow I need to specify that I will need these files so they get added to the list of assets. I think it needs to work the same way favicon does.

        <link rel="apple-touch-icon" href="assets/img/touch-icon-iphone.png">
        <link rel="apple-touch-icon" sizes="76x76" href="assets/img/touch-icon-ipad.png">
        <link rel="apple-touch-icon" sizes="120x120" href="assets/img/touch-icon-iphone-retina.png">
        <link rel="apple-touch-icon" sizes="152x152" href="assets/img/touch-icon-ipad-retina.png">
@jantimon
Copy link
Owner

@AsaAyers
Copy link
Author

How close is this 2.0 branch to being ready? I have a production browserify project that I'm almost done converting to webpack. This is the last piece of the puzzle.

@jantimon
Copy link
Owner

Well - I guess 2.0 is more or less feature complete but might need some further improvements.

If you don't want to use the 2.0 beta of this plugin might help you: https://www.npmjs.com/package/transfer-webpack-plugin

@AsaAyers
Copy link
Author

Thanks. I'm trying out your branch. It doesn't seem to be picking up my files automatically, but I can do this and it works. ¯_(ツ)_/¯

    <link rel="apple-touch-icon" href="<%= require('./assets/img/touch-icon-iphone.png') %>">

@jantimon
Copy link
Owner

If it doesn't picking up links it might be a bug of the html-loader

@bmueller-sykes
Copy link

I'm after the exact same thing. I'd like to be able to inject images (and possibly even css files) into a template, and then have those assets get built as part of the normal webpack build. I'm not specifically seeing a "2.0" branch. Do you mean the "feature/loaders" branch?

@jantimon
Copy link
Owner

Yeah that's the one.. however it seems like that the extract-text-plugin does not work with child compilations.. so css is not supported by now

@lock
Copy link

lock bot commented Jun 1, 2018

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Jun 1, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants