orbitntnu.com is a website for the student organization Orbit NTNU.
Live @ orbitntnu.com
- Typescript
- JavaScript with syntax for types 💪
- React
- Component based JavaScript library used for creating user interfaces 🌿
- Gatsby
- Blazing fast React framework 🚀
- Tailwind
- Utility-first CSS framework 💅
- Sanity
- CMS used to manage the websites content ✅
# Cloning the repository
git clone https://github.com/OrbitNTNU/orbitntnu-web.git
cd orbitntnu-web
# Installing frontend dependencies
cd frontend
yarn install
cd ..
# Installing sanity dependencies
cd sanity
yarn install
cd ..
cd frontend
yarn start
cd sanity
yarn start
Any changes made to the main
branch in the repository will automaticly be built and deployed.
This project uses Netlify hosting.
Find the schema to which you want to add a component in /sanity/schemas
Documentation for Sanity components
# Add your component
{
name: "exampleName",
type: "Text",
title: "Title in Sanity"
}
Push and merge to the main branch.
# Installing the Sanity CLI globally
npm install --global sanity@latest # This worked for Windows
sanity login
# Alternatively
yarn global add sanity@latest
pnpm install --global sanity@latest
sanity login
# Running the CLI without global installation
npx -y sanity@latest login # This worked for Linux
cd sanity
yarn run build
yarn run graphql-deploy
Add exampleName
to the graphql query at the bottom of the page you're
changing in /frontend.
You can now use nameOfSanitySchema.exampleName
in your code with the