trunk-rs/trunk

Feature request: preload option for copy-file assets

Ouverte

#787 ouverte le 1 mai 2024

 (1 commentaire) (2 réactions) (0 personne assignée)Rust (315 forks)auto 404
enhancementhelp wanted

Métriques du dépôt

Stars
 (4 347 étoiles)
Métriques de merge PR
 (Métriques PR en attente)

Description

Hello,

It would be nice to have a shortcut to also preload a copied file.

Instead of this:

<link data-trunk rel="copy-file" href="assets/ui/button.svg" />
<link rel="preload" as="image" href="button.svg" />

Just write something like that:

<link data-trunk data-preload="image" rel="copy-file" href="assets/ui/button.svg" />

Guide contributeur