Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Three items #1

Open
coding-to-music opened this issue Dec 13, 2021 · 0 comments
Open

Three items #1

coding-to-music opened this issue Dec 13, 2021 · 0 comments

Comments

@coding-to-music
Copy link

Hi, really enjoyed this tutorial
I have this repo: https://github.com/coding-to-music/supabase-nextjs-todo-app
And the readme is the same as this issue: coding-to-music/coding-to-music.github.io#340

I have three items you might want to be aware of

  1. The directory components is plural, this sentence uses singular: "Create a component directory under the root directory, and inside the component directory"
  2. This mentions going up two levels, it probably is only one level? import { supabaseClient } from "../../lib/client";
  3. When I then attempt to do a build, I get the following error, not sure how to proceed?

https://github.com/coding-to-music/supabase-nextjs-todo-app/blob/main/README.md#how-to-deploy-the-app-to-vercel-and-configure-supabase-authentication

> build
> next build

info  - Loaded env from /mnt/ap/ap/supabase-nextjs-todo-app/.env.local
info  - Checking validity of types  
info  - Creating an optimized production build  
info  - Compiled successfully
info  - Collecting page data  
[    ] info  - Generating static pages (0/6)
Error occurred prerendering page "/auth". Read more: https://nextjs.org/docs/messages/prerender-error
TypeError: res.setHeader is not a function
    at GoTrueApi.setAuthCookie (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/@supabase/gotrue-js/dist/main/GoTrueApi.js:377:17)
    at handler (/mnt/ap/ap/supabase-nextjs-todo-app/.next/server/pages/auth.js:35:102)
    at d (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:33:498)
    at bb (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:36:16)
    at a.b.render (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:42:43)
    at a.b.read (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:41:83)
    at Object.exports.renderToString (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/react-dom/cjs/react-dom-server.node.production.min.js:52:138)
    at Object.renderPage (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/server/render.js:686:46)
    at Object.defaultGetInitialProps (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/server/render.js:316:51)
    at Function.getInitialProps (/mnt/ap/ap/supabase-nextjs-todo-app/.next/server/chunks/859.js:515:20)
info  - Generating static pages (6/6)

> Build error occurred
Error: Export encountered errors on following paths:
        /auth
    at /mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/export/index.js:500:19
    at runMicrotasks (<anonymous>)
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
    at async Span.traceAsyncFn (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/trace/trace.js:74:20)
    at async /mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/build/index.js:987:17
    at async Span.traceAsyncFn (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/trace/trace.js:74:20)
    at async /mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/build/index.js:861:13
    at async Span.traceAsyncFn (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/trace/trace.js:74:20)
    at async Object.build [as default] (/mnt/ap/ap/supabase-nextjs-todo-app/node_modules/next/dist/build/index.js:82:25)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant