new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Supabase · all subjects

out of scope - mobile framework specifics

7 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

Create Refine app with Supabase preset

Use the command `npm create refine-app@latest -- --preset refine-supabase my-app` to create a Refine app with the refine-supabase preset. This preset adds the @refinedev/supabase supplementary package that supports Supabase in a Refine app and includes the supabase-js dependency out-of-the-box.

Skip email prompt in Refine CLI non-interactive shell

To skip the email prompt when creating a Refine app in a non-interactive shell, pipe a blank line using: `printf '\n' | npm create refine-app@latest -- --preset refine-supabase my-app`

Environment variables for Supabase in Refine

Create a .env file with VITE_SUPABASE_URL and VITE_SUPABASE_PUBLISHABLE_KEY variables. These values can be obtained from the project Connect panel. The refine-supabase preset hardcodes demo credentials in src/providers/constants.ts and src/providers/supabase-client.ts which should be replaced to read from these environment variables.

Update Supabase constants in Refine

Replace hardcoded values in src/providers/constants.ts with: `export const SUPABASE_URL = import.meta.env.VITE_SUPABASE_URL` and `export const SUPABASE_KEY = import.meta.env.VITE_SUPABASE_PUBLISHABLE_KEY`

Install Refine Inferencer dependencies

To use the HeadlessInferencer component for generating pages, install dependencies: `npm install @refinedev/react-table @refinedev/react-hook-form react-live`

Create Refine resource with CLI

Use the command `npm run refine create-resource instruments` to automatically add resources and generate code for pages with the HeadlessInferencer component. This creates pages for list, create, show, and edit actions in the src/pages/instruments/ directory.

Refine app development server default port

Run `npm run dev` to start the development server. Vite defaults to http://localhost:5173. Navigate to /instruments in the browser to see the instruments pages.

Give your agent this brain