fix(landing-page): make starfield load first

This commit is contained in:
Ayo 2022-11-07 11:56:46 +01:00
parent 007f56c1b9
commit 251c7681d5
2 changed files with 5 additions and 3 deletions

View file

@ -3,7 +3,8 @@ import Header from "~/components/header.astro";
// import Icon from "astro-icon"; // import Icon from "astro-icon";
import Splash from "~/sections/splash.astro"; import Splash from "~/sections/splash.astro";
import "~/styles/index.css"; import "~/styles/index.css";
import AstroSection from "~/sections/astro-section.astro"; // import AstroSection from "~/sections/astro-section.astro";
import Starfield from "~/sections/starfield.astro";
const { site } = Astro; const { site } = Astro;
const image = new URL("social.jpg", site); const image = new URL("social.jpg", site);
@ -79,5 +80,7 @@ const description =
<Header /> <Header />
<Splash /> <Splash />
<!--AstroSection /--> <!--AstroSection /-->
<Starfield client:load />
</body> </body>
</html> </html>

View file

@ -1,7 +1,7 @@
--- ---
import { generateImage } from "astro-eleventy-img"; import { generateImage } from "astro-eleventy-img";
import { Icon } from "astro-icon"; import { Icon } from "astro-icon";
import Starfield from "~/sections/starfield.astro"; // import Starfield from "~/sections/starfield.astro";
import Copynpm from "~/components/copynpm.astro"; import Copynpm from "~/components/copynpm.astro";
const widths = [450, 800]; const widths = [450, 800];
@ -64,7 +64,6 @@ const pngSrcset = png.map(({ srcset }) => srcset).join(",");
/> />
</picture> </picture>
</div> </div>
<Starfield client:load />
</section> </section>
<noscript> <noscript>