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

Support for <link rel="stylesheet"> tag? #5

Open
StanislavUngr opened this issue Feb 13, 2019 · 0 comments
Open

Support for <link rel="stylesheet"> tag? #5

StanislavUngr opened this issue Feb 13, 2019 · 0 comments

Comments

@StanislavUngr
Copy link

Hello. I have a problem when trying to use this bundle on my current twig files.

In https://github.com/tijsverkoyen/CssToInlineStyles I have read that <link rel="stylesheet"> tags are supported, however this bundle ignores them. I tried it even without using webpack manifest file and its still the same.

Is it possible to extend this functionality? Somehow I cannot imagine manually rewriting 5MB of CSS in every template 😄

Example code:

inline.html.twig

{% cssinline %}
    <html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <link rel="stylesheet" href="{{ asset('build/test.css') }}">
    </head>
    <body>
        <p class="red text-white">Red & white</p>
    </body>
    </html>
{% endcssinline %}

test.css

.red{
    background-color: red;
}
.text-white{
    color: white !important;
}
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

1 participant