You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+5-1Lines changed: 5 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,11 @@
2
2
3
3
Thank you for your interest in contributing to the Supabase JavaScript client libraries! This guide will help you get started with contributing to the Supabase JS monorepo.
4
4
5
-
> **📣 Coming from a separate repository?** The `supabase-js` repository has been converted into a monorepo and all other Supabase JS libraries have been absorbed into it. If you previously contributed to `auth-js`, `postgrest-js`, `realtime-js`, `storage-js`, or `functions-js`, please read our **[Migration Guide](docs/MIGRATION.md)** to understand the new structure, workflow changes, and command mappings.
5
+
> **Repository Structure Changed:** This repository has been restructured as a monorepo. **All libraries, including `supabase-js`, are now under `packages/core/`**. If you previously contributed to `supabase-js`, `auth-js`, `postgrest-js`, `realtime-js`, `storage-js`, or `functions-js`, please read our **[Migration Guide](docs/MIGRATION.md)** to understand:
6
+
>
7
+
> - Where your code moved (everything is now in `packages/core/<library-name>/`)
8
+
> - How commands changed (`npm test` → `npx nx test <library-name>`)
Copy file name to clipboardExpand all lines: README.md
+16-1Lines changed: 16 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,22 @@
6
6
7
7
_The Supabase JS monorepo containing all the Supabase JavaScript client libraries._
8
8
9
-
> **📣 Coming from our old repositories?** The `supabase-js` repository has been converted into a monorepo and all other client libraries have been absorbed into it. If you previously contributed to individual repositories like `auth-js`, `postgrest-js`, `realtime-js`, `storage-js`, or `functions-js`, please see our **[Migration Guide](./docs/MIGRATION.md)** to learn about the new structure and workflows.
9
+
> **IMPORTANT: Repository Structure Changed**
10
+
>
11
+
> This repository has been restructured as a monorepo. **All libraries, including `supabase-js` itself, have moved to `packages/core/`**:
12
+
>
13
+
> | What You're Looking For | Where It Is Now |
14
+
> |------------------------|-----------------|
15
+
> | Main supabase-js code |`packages/core/supabase-js/`|
Copy file name to clipboardExpand all lines: docs/MIGRATION.md
+91-9Lines changed: 91 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,61 @@
1
-
# Migration Guide: From Separate Repos to the Supabase JS Monorepo
1
+
# Migration Guide: Transitioning to the Supabase JS Monorepo
2
2
3
-
> 🚀 **Welcome to the Supabase JS monorepo!** This guide will help you transition from the old separate repository structure to our new Nx monorepo.
3
+
> 🚀 **Welcome to the Supabase JS monorepo!** This repository has been completely restructured. Whether you contributed to `supabase-js`, `auth-js`, `postgrest-js`, or any other Supabase JS library, this guide will help you understand what changed and how to work with the new structure.
4
+
5
+
## 🎯 Who This Guide Is For
6
+
7
+
This guide is for:
8
+
9
+
-**Contributors to the old `supabase-js` repository** - Yes, even supabase-js moved!
10
+
-**Contributors to separate libraries** (`auth-js`, `postgrest-js`, `realtime-js`, `storage-js`, `functions-js`)
11
+
-**Anyone with open PRs** in any of the old repositories
12
+
-**New contributors** who want to understand the architecture
13
+
14
+
## What Changed: The Big Picture
15
+
16
+
### The Repository URL Stayed the Same, But Everything Inside Changed
17
+
18
+
**Important:** The repository is still at `github.com/supabase/supabase-js`, but:
19
+
20
+
**OLD Structure** (what you remember):
21
+
22
+
```tree
23
+
github.com/supabase/supabase-js/
24
+
├── src/ ← supabase-js code was here
25
+
├── test/
26
+
├── package.json
27
+
└── README.md
28
+
29
+
github.com/supabase/auth-js/ ← Separate repo
30
+
github.com/supabase/postgrest-js/ ← Separate repo
31
+
github.com/supabase/realtime-js/ ← Separate repo
32
+
github.com/supabase/storage-js/ ← Separate repo
33
+
github.com/supabase/functions-js/ ← Separate repo
34
+
```
35
+
36
+
**NEW Structure** (what you'll see now):
37
+
38
+
```tree
39
+
github.com/supabase/supabase-js/ ← Same URL, different structure!
40
+
├── packages/
41
+
│ └── core/
42
+
│ ├── supabase-js/ ← YOUR supabase-js code is HERE now
43
+
│ │ ├── src/
44
+
│ │ ├── test/
45
+
│ │ └── package.json
46
+
│ ├── auth-js/ ← auth-js moved here
47
+
│ ├── postgrest-js/ ← postgrest-js moved here
48
+
│ ├── realtime-js/ ← realtime-js moved here
49
+
│ ├── storage-js/ ← storage-js moved here
50
+
│ └── functions-js/ ← functions-js moved here
51
+
├── nx.json ← New: Nx workspace config
52
+
├── package.json ← New: Root workspace config
53
+
└── README.md
54
+
```
55
+
56
+
### Key Point: EVERYTHING Moved
57
+
58
+
**All six libraries**, including `supabase-js` itself, now live under `packages/core/`. This is not a case where some libraries moved "into" supabase-js - rather, **all libraries were reorganized into a shared monorepo structure**.
### Q: I contributed to the old supabase-js repo. Where did my code go?
344
+
345
+
**A:** The old `supabase-js` repository code is now in `packages/core/supabase-js/`. The repository URL (`github.com/supabase/supabase-js`) stayed the same, but the internal structure changed completely. What used to be in the root (`src/`, `test/`, etc.) is now nested under `packages/core/supabase-js/`.
This was necessary to accommodate all the other libraries in a unified structure.
353
+
354
+
### Q: Why does it say supabase-js "absorbed" other libraries if supabase-js also moved?
355
+
356
+
**A:** That's admittedly confusing wording! What actually happened:
357
+
358
+
- The `supabase-js`**repository URL** stayed the same (`github.com/supabase/supabase-js`)
359
+
- But **all libraries** (including supabase-js itself) moved into a `packages/core/` structure
360
+
- Other library repositories (`auth-js`, `postgrest-js`, etc.) were archived
361
+
- So the repository "absorbed" them in the sense that it now contains all libraries, but supabase-js code itself also relocated
362
+
363
+
Think of it as: the **repository** absorbed other libraries, but the **supabase-js package code** also moved.
364
+
288
365
### Q: Why fixed versioning instead of independent versions?
289
366
290
367
**A:** Fixed versioning ensures all Supabase JS libraries are always compatible with each other. Users don't need to worry about compatibility matrices or which version of auth-js works with which version of supabase-js.
@@ -308,7 +385,12 @@ npx nx test auth-js --watch
308
385
309
386
### Q: How do I know which files to edit?
310
387
311
-
**A:** The structure within each package is the same as before. If you edited `src/GoTrueClient.ts` in the old auth-js repo, you'll now edit `packages/core/auth-js/src/GoTrueClient.ts`.
388
+
**A:** The structure within each package is the same as before. Examples:
0 commit comments