cwdevteam / mesa

https://mesa-wallet.vercel.app
1 stars 1 forks source link

Project setup #1

Closed neatonk closed 8 months ago

neatonk commented 8 months ago

Steps to complete:

neatonk commented 8 months ago

Create mesa GitHub repo

See the repo attached to this issue.

Create mesa Supabase project

https://supabase.com/dashboard/project/ewvzsofyvxcctuxxqibo

neatonk commented 8 months ago

Init repo with Nexjs, Supabase, and Prisma.

See https://supabase.com/docs/guides/getting-started/quickstarts/nextjs

Init repo with bun:

bunx create-next-app@latest --use-bun mesa && cd mesa

Connect to remote GitHub repo:

git remote add origin git@github.com:AbstractGoods/mesa.git
git branch -M main
git push -u origin main
neatonk commented 8 months ago

Not using the Supabase example because it didn't work out of the box and included some cruft I would otherwise have to remove.

neatonk commented 8 months ago

Following this guide instead: https://supabase.com/docs/guides/getting-started/tutorials/with-nextjs

neatonk commented 8 months ago

Tried to install and use the supabase CLI:

bun i supabase --save-dev

But there is no bin in the release so it would not run. Skipping this for now.

See #2

neatonk commented 8 months ago

Added typegen script to generate Typescript types from the remote db schema. Ideally, we would be able to check in the database schema and generate types from that.

https://supabase.com/docs/reference/cli/supabase-gen-types-typescript

neatonk commented 8 months ago

Vercel Links:

neatonk commented 8 months ago

Build errors:

DynamicServerError: Dynamic server usage: Page couldn't be rendered statically because it used `cookies`. See more info here: https://nextjs.org/docs/messages/dynamic-server-error
--
14:37:49.001 | at staticGenerationBailout (/vercel/path0/.next/server/chunks/650.js:1:1634)
14:37:49.001 | at Object.cookies (/vercel/path0/.next/server/chunks/790.js:1:255276)
14:37:49.001 | at g.getCookie (/vercel/path0/.next/server/chunks/790.js:1:4965)
14:37:49.001 | at g.getItem (/vercel/path0/.next/server/chunks/790.js:1:12995)
14:37:49.001 | at getItemAsync (/vercel/path0/.next/server/chunks/790.js:1:64215)
14:37:49.002 | at SupabaseAuthClient._recoverAndRefresh (/vercel/path0/.next/server/chunks/790.js:1:45709)
14:37:49.002 | at SupabaseAuthClient._initialize (/vercel/path0/.next/server/chunks/790.js:1:25561)
14:37:49.002 | at /vercel/path0/.next/server/chunks/790.js:1:24835
14:37:49.002 | at /vercel/path0/.next/server/chunks/790.js:1:35327
14:37:49.002 | at SupabaseAuthClient.lockNoOp [as lock] (/vercel/path0/.next/server/chunks/790.js:1:22253) {
14:37:49.002 | digest: 'DYNAMIC_SERVER_USAGE'

See https://nextjs.org/docs/messages/dynamic-server-error

neatonk commented 8 months ago

Done