Scthe's blog - https://www.sctheblog.com/
yarn install
yarn start
- Accessible at: http://localhost:8080, http://localhost:8080/___graphql
yarn gatsby clean
I hate Gatsby.
I hate Gatsby. Open src\templates\blog-post.tsx
and press ctrl+s
to reconnect hmr.
Vercel's Gatsby integration throws errors on git push hook: Field "image" of type "File" must have a selection of subfields
. "We'll do it live":
npm i -g vercel
- (Optional)
npm i -g vercel@latest
- (One time)
vercel login
git s
- check if all local articles are publishable i.e. no drafts incontent\blog
vercel build
- verify:
http-server .
in.vercel\output\static
vercel deploy --prebuilt
- generate draft deploy- Check the preview link from CLI output
vercel --prod
- push to live
- Install node and yarn
nvm install v20.10.0
nvm use v20.10.0
corepack enable
- add yarn
- Clean repo
yarn cache clean
- just in case- Delete
yarn.lock
- Upgrade packages
yarn upgrade-interactive
- select packages to upgradeyarn install
yarn dlx @yarnpkg/sdks vscode
- one time onlyyarn start
- dev server
useStaticQuery()
can be used from everywhere. Other types of queries have some constraints.