{"id":22609587,"url":"https://github.com/ncrmro/remix-supabase-playwright","last_synced_at":"2025-04-11T06:33:07.663Z","repository":{"id":265430324,"uuid":"613632673","full_name":"ncrmro/remix-supabase-playwright","owner":"ncrmro","description":"A boilerplate for website using Remix.JS, Supabase as a backend and Playwright for E2E testing.","archived":false,"fork":false,"pushed_at":"2023-03-16T02:05:49.000Z","size":325,"stargazers_count":10,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-06T15:54:28.369Z","etag":null,"topics":["playwright","postgresql","react","remix","supabase"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ncrmro.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-14T00:39:46.000Z","updated_at":"2024-11-16T09:50:53.000Z","dependencies_parsed_at":"2024-11-29T11:08:27.903Z","dependency_job_id":"314bba56-608d-4871-a320-f8788633f69a","html_url":"https://github.com/ncrmro/remix-supabase-playwright","commit_stats":null,"previous_names":["ncrmro/remix-supabase-playwright"],"tags_count":0,"template":true,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ncrmro%2Fremix-supabase-playwright","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ncrmro%2Fremix-supabase-playwright/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ncrmro%2Fremix-supabase-playwright/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ncrmro%2Fremix-supabase-playwright/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ncrmro","download_url":"https://codeload.github.com/ncrmro/remix-supabase-playwright/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248357197,"owners_count":21090364,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["playwright","postgresql","react","remix","supabase"],"created_at":"2024-12-08T15:13:45.042Z","updated_at":"2025-04-11T06:33:07.630Z","avatar_url":"https://github.com/ncrmro.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Welcome to Remix Supabase Playwright!\n\n- [Remix Docs](https://remix.run/docs)\n- [Playwright Docs](https://playwright.dev/docs/intro)\n- [Supabase CLI Docs](https://supabase.com/docs/guides/cli)\n- [Supabase JS Client Docs](https://supabase.com/docs/reference/javascript/introduction)\n\n## Development\n\nFrom your terminal:\n\n```sh\nsupabase start\n```\n\n```sh\nyarn run dev\n```\n\nThis starts your app in development mode, rebuilding assets on file changes.\n\n### Testing\n\nPlaywright tests can be ran with:\n\n```sh\nyarn test\n```\n\nRunning only tests containing `signup`\n\n```sh\nyarn test -g signup\n```\n\n#### [Playwright fixtures](https://playwright.dev/docs/test-fixtures)\n\nBy specifying the user fixture `async ({ page, user })`\n\nPlaywright will set the Supabase session cookie and all the user will already be authenticated durign the test.\n\n```typescript\nimport { test } from \"./fixtures\";\n\ntest(\"Already authenticated user\", async ({ page, user }) =\u003e {\n  await page.goto(\"/todos\");\n});\n```\n\n---\n\nThe database fixture `async ({ page, db })`\n\n```typescript\nimport { test } from \"./fixtures\";\n\ntest(\"Already authenticated user\", async ({ page, db }) =\u003e {\n  await page.goto(\"/todos/new\");\n  // Create todo on frontend...\n\n  await db.query(\n    `SELECT * FROM todos WHERE user_id=$1`,\n    [user.id]\n  );\n  \n  // Wait for query will retry the query until the last paramter returns true or timeout.\n  await db.waitForQuery(\n    `SELECT * FROM todos WHERE user_id=$1`,\n    [user.id],\n    ({ rowCount }) =\u003e rowCount === 1\n  );\n});\n```\n\n## Deployment\n\nIf you've made any database migrations that are ready to be pushed to a live Supabase instance.\n\n```sh\nsupabase db push\n```\n\nFirst, build your app for production:\n\n```sh\nyarn run build\n```\n\nThen run the app in production mode:\n\n```sh\nyarn start\n```\n\nNow you'll need to pick a host to deploy it to.\n\n### DIY\n\nIf you're familiar with deploying node applications, the built-in Remix app server is production-ready.\n\nMake sure to deploy the output of `remix build`\n\n- `build/`\n- `public/build/`\n\n### Using a Template\n\nWhen you ran `npx create-remix@latest` there were a few choices for hosting. You can run that again to create a new project, then copy over your `app/` folder to the new project that's pre-configured for your target server.\n\n```sh\ncd ..\n# create a new project, and pick a pre-configured host\nnpx create-remix@latest\ncd my-new-remix-app\n# remove the new project's app (not the old one!)\nrm -rf app\n# copy your app over\ncp -R ../my-old-remix-app/app app\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fncrmro%2Fremix-supabase-playwright","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fncrmro%2Fremix-supabase-playwright","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fncrmro%2Fremix-supabase-playwright/lists"}