GithubHelp home page GithubHelp logo

cocina214.com's Introduction

Astro + Sanity Project Template Repo

This template repo should be used upon starting a new Huge Project. It uses Huge of course, and other useful TND modules and project structure plus loads some basic templates.

Update values

Search and replace the following {strings} in the project with:

cocina214 > Site ID, a string or int with alphanumeric chars (ex: mywebsite) Cocina 214 > Site Title (ex: My Website) https://www.cocina214.com > Site URL (ex: https://www.mywebsite.com) d8r8fz1h > Sanity project ID (ex: sxxx2w)

Env

Add following filled values as /cms/.env

SANITY_STUDIO_PROJECT_ID="d8r8fz1h"
SANITY_STUDIO_DATASET="production"
SANITY_STUDIO_PROJECT_TITLE="{sanityProjectTitle}"
SANITY_STUDIO_API_VERSION="2022-11-15"
SANITY_STUDIO_USECDN="true"

Setup

npm install
cd cms
npm install

CSS

Handled mostly through tailwind and in-components style tags. We use a styles/main.css style for anything that cannot live in components which is imported through the Base component.

Media

Images are handled using the Image component. It takes a mandatory image parameter which is an object containg information on said image OR a string in which case, this will be used as is as the image src.

SEO

SEO is handled and manipulated from the /util/seo file. Each entry is expecting an optional seo object containing the user overrides.

Google Analytics

See data/site.js ga_id key.

cocina214.com's People

Contributors

budparr avatar regisphilibert avatar

Watchers

 avatar  avatar

cocina214.com's Issues

Update Software

Currently 2.92. Not a rush, but I think if it gets too far behind could be a liability for us.

  • Upgrade Astro
  • Upgrade Sanity
  • Host on Cloudflare

Also, the site is hosted on the client's Netlify, but I think we could just put it on our Cloudflare because the client had an issue and I had to go hunt down her hosting to troubleshoot.

CMS: Create custom string selector for block theme

I'd really like to use this tutorial to give editors a better experience when chosing style impacting options.

https://www.sanity.io/guides/create-a-rich-string-selector-field-input

I know we have a solution based on the color set, but this does not give a detailed idea of the upcoming styling (except for one of the used color) and requires to use said color as the value saved.

With the custom component solution we could:

  1. present a button styled as a minimal representation of the block itself, which could preview the colors of the title, copy text border etc...
  2. Finally train ourselves on custom input component with which we could bring our editors experience to the next level.

Capture d’écran, le 2023-07-10 à 13 25 01

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.