v0.1.5 #67
regisphilibert
announced in
Announcements
v0.1.5
#67
Replies: 1 comment
-
|
In order to start "experimenting" with Tailwind JIT, all you need to do is
styles:
- name: main
path: css/style.scss
use:
- tailwind-jitAlso be aware this will produce a new |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
This release mostly addresses fonts and adds an experimental "Tailwind JIT" transformation to styles.
huge/Fonts: performance optimization with
preloadand more!preloadA past mistake was to use
prefetchin order to direct browsers to load the font files ASAP. This has been corrected by implementing apreloadsetting and retiringprefetch. Huge will no longer userel="prefetch"for fonts "preloading". but arel="preload"along side other proper attributes:WARNING: This for now is limited to
woff2files as this is the most supported, most efficient format. Other file formats won't be "preloaded".Only
preloadcertain fonts.It's good practice to only preload certain font files (needed above the fold, or on most of the pages), so while by default, Huge will preload every
woff2file, users can overwrite thepreloadsetting as per declaration regardless of the globalpreloadsetting.@font-facesrclist order.It recently came to the attention of this project's maintainers that the browser will load the first "supported" font file from the
@font-facedeclaration! So listing the font files in alphabetical order would result inwoffbeing used instead of the much betterwoff2and for projects also usingttf, making the much heavierttfused overwofforwoff2.From now on, Huge will declare the font files in the following order:
woff2,woff,ttf,svg,eot.huge/Styles: Tailwind JIT
This is an experimental feature based on the work of @Gioni06 detailed here. It allows Hugo users to upgrade to Tailwind 3 pending resolution of gohugoio/hugo#8343
It introduced a new transformation called
tailwind-jitfor use in theusearray of a registered style.This won't be documented while it's experimental but you should know using this will generate a new resource in your
resource/_gendirectory every time you save. It's perfectly fine if like many your whole resource folder is ignored by git, but be aware and use it at your own risk.What's Changed
preload, retireprefetchby @regisphilibert in Fonts: Fine tunepreload, retireprefetch#64preloadsetting by @regisphilibert in Allow per-declarationpreloadsetting #66Full Changelog: v0.1.4...v0.1.5
This discussion was created from the release v0.1.5.
Beta Was this translation helpful? Give feedback.
All reactions