Skip to content

Instantly share code, notes, and snippets.

View erasebegin's full-sized avatar

Chris Haupt erasebegin

View GitHub Profile
@erasebegin
erasebegin / page.tsx
Created April 11, 2024 09:35
Example of Hygraph in Next 14
import { Suspense } from "react";
import MaterialsSections from "./components/MaterialsSections";
import PageHeader from "./components/PageHeader";
import { Loader2 } from "lucide-react";
export default async function Home() {
const { errors, data } = await fetch(process.env.HYGRAPH_URL as string, {
method: "POST",
headers: {
"Content-Type": "application/json",
import React, { useState, useEffect } from "react";
import styled from "styled-components";
import Panel from "./Panel";
import TrayButton from "./TrayButton";
import Tech from "./skills/Tech";
import Illustration from "./skills/Illustration";
import Misc from "./skills/Misc";
import trayIconSkills from "../../../img/tray-icon-fixed.svg";
import trayIconContact from "../../../img/tray-icon3.svg";
import { BsFillEnvelopeFill, BsFillEnvelopeOpenFill } from "react-icons/bs";