Skip to content

Option for adding additional files#16

Open
ste101 wants to merge 1 commit intob13:masterfrom
ste101:patch-1
Open

Option for adding additional files#16
ste101 wants to merge 1 commit intob13:masterfrom
ste101:patch-1

Conversation

@ste101
Copy link
Contributor

@ste101 ste101 commented May 17, 2021

This patch works for me.
I think it could be done better.

Files can be added like this:

plugin.tx_http2 {
    settings {
        before {
            fontRegular.file = EXT:user_pizpalue/Resources/Public/Fonts/source-sans-pro-v14-latin-regular.woff2
            fontRegular.type = font
            fontRegular.mime = font/woff2
            fontRegular.crossorigin = anonymous
        }
        after {
            fontAwesome.file = EXT:user_pizpalue/Resources/Public/Fonts/fa-solid-900.woff2
            fontAwesome.type = font
            fontAwesome.mime = font/woff2
            fontAwesome.crossorigin = anonymous
            fontAwesome.rel = prefetch
        }
    }
}

With a little more other preload option could be added:
https://3perf.com/blog/link-rels/

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

Successfully merging this pull request may close these issues.

1 participant