Skip to content

Commit

Permalink
feat(apps/earth): changes root and head
Browse files Browse the repository at this point in the history
removes uneeded code

also adds google fonts links
  • Loading branch information
deopea-david committed Jan 23, 2023
1 parent b189307 commit 10d5a19
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 11 deletions.
6 changes: 6 additions & 0 deletions apps/earth/src/components/head/Head.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,12 @@ const Head = component$(() => {
<link rel="canonical" href={loc.href} />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="icon" type="image/svg+xml" href="/favicon.svg" />
<link rel="preconnect" href="https://fonts.googleapis.com" />
<link rel="preconnect" href="https://fonts.gstatic.com" crossOrigin="" />
<link
href="https://fonts.googleapis.com/css2?family=Quicksand:wght@300;400;700&family=Space+Mono&display=swap"
rel="stylesheet"
/>

{head.meta.map((m) => (
<meta {...m} />
Expand Down
13 changes: 2 additions & 11 deletions apps/earth/src/root.tsx
Original file line number Diff line number Diff line change
@@ -1,21 +1,12 @@
import { component$, useStyles$ } from "@builder.io/qwik";
import { component$ } from "@builder.io/qwik";
import {
QwikCityProvider,
RouterOutlet,
ServiceWorkerRegister,
} from "@builder.io/qwik-city";
import Head from "./components/head/Head";
import globalStyles from "./global.css?inline";
import Head from "components/head/Head";

export default component$(() => {
/**
* The root of a QwikCity site always start with the <QwikCityProvider> component,
* immediately followed by the document's <head> and <body>.
*
* Dont remove the `<head>` and `<body>` elements.
*/
useStyles$(globalStyles);

return (
<QwikCityProvider>
<Head />
Expand Down

0 comments on commit 10d5a19

Please sign in to comment.