Workspace Switcher
Move between organizations without mixing their data.
What it adds
A switcher for users who belong to several workspaces, with clean state isolation on every switch.
What your agent is told to do
5
What your agent is told to do
5-
1
Show the current workspace at all times, prominently enough that nobody edits the wrong account's data by accident.
-
2
Resolve the active workspace on the server from the session or the URL. Never trust a client-held value to scope a query.
-
3
On switch, clear every piece of cached state tied to the previous workspace: query caches, filters, drafts, selections, realtime subscriptions.
-
4
Map the current route into the new workspace where an equivalent exists, and fall back to that workspace's home when it does not.
-
5
Do NOT switch by reassigning a variable and re-rendering. Anything that survives the switch is a data leak waiting to be reported.
Edge cases it handles
7
Edge cases it handles
7- A user removed from a workspace mid-session must be moved out of it immediately, not at their next page load.
- Suspended, pending-invitation, and past-due workspaces need their own states, not a generic error.
- A stored last-used workspace the user no longer belongs to must fail closed to a valid one.
- Realtime subscriptions and analytics contexts must be torn down and rebuilt, or events cross workspace boundaries.
- Open tabs on the old workspace must not silently start writing to the new one. Scope by tab or reload them.
- Unsaved drafts should be preserved against the workspace they belong to, not carried across or silently discarded.
- A user in a single workspace should not see a switcher at all.
Definition of done
8
Definition of done
8- The active workspace is visible on every screen.
- Workspace scope is resolved server-side on every request.
- Switching clears caches, filters, drafts, selections, and subscriptions from the previous workspace.
- The equivalent route is preserved where it exists, with a safe fallback where it does not.
- Removed, suspended, and pending memberships each have distinct handling.
- No API response, analytics event, or realtime message crosses workspace boundaries.
- The feature matches the existing design system.
- No existing functionality is broken.
Related features
Tabs
Tabs
Split a crowded page into sections without another route.
What it does
Accessible tabbed sections, with the active tab reflected in the URL.
How it works
- 1 Use tabs for alternative views of the SAME thing. If the content is unrelated, it wants a separate page.
- 2 Put the active tab in the URL so a tab can be linked, bookmarked, and survives a refresh.
- 3 Implement the WAI-ARIA tabs pattern: arrow keys move between tabs, Tab moves into the panel.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/tabs
Pagination
Pagination
Split long lists into numbered pages without losing filters or the user's place.
What it does
Discrete paged lists with an explicit page control, where page number, page size, filters, and sort all live in the URL.
How it works
- 1 Build a real page control: previous, next, and a way to jump to a specific page or the last page. This feature is for lists people navigate deliberately. If the list is a feed people graze, choose progressive appending instead.
- 2 Put page, page size, filters, and sort in the URL so every page is linkable, bookmarkable, and survives a refresh.
- 3 Show enough context to orient: current page, total pages or a clear next-page affordance, and the range of items shown out of the total.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/pagination
Deep-Linkable Modals
Deep-Linkable Modals
Make dialogs and detail panels linkable without losing the page behind them.
What it does
Modals and detail panels that live at their own URL, so they can be shared, bookmarked, and closed with the back button.
How it works
- 1 Pick the overlays worth linking — record detail, edit forms, share dialogs — and give each one a real URL.
- 2 When that URL is opened directly, with no page underneath, render the content as a full page instead of an overlay floating on nothing.
- 3 Make the browser back button close the modal and leave the user on the page they were on, not two steps back.
Copy the prompt
No account needed
Add this feature to my app:
https://addthisfeature.com/x/deep-linkable-modals
How it works
-
1
Copy the link
Grab the Markdown instruction URL for this feature.
-
2
Give it to your AI
Paste it into Claude Code, Cursor, v0, Lovable — whatever you build with.
-
3
It inspects, then implements
Your agent reads your existing app first, then adds the feature to fit it.
Works with your stack
These instructions are written to adapt. They tell the agent to detect your framework, match your existing design system, and reuse what you already have — rather than assuming a particular stack.
Need it tighter than that? Customize the feature and tell it exactly what you're running.