Skip to content

Conversation

coryhouse
Copy link
Contributor

@coryhouse coryhouse commented Jul 17, 2025

The server key is ambiguous, especially since a web app has a webserver, a push endpoint which might be on a different server, and likely other servers. So, suggest renaming to clarify.

If this is accepted, then I suggest updating example apps to reference the Vite env var like this:

const z = new Zero({
  userID,
  auth: () => encodedJWT,
  cacheServerUrl: import.meta.env.VITE_ZERO_CACHE_SERVER_URL, 
  schema,
});

(hello-zero currently uses VITE_PUBLIC_SERVER which is ambiguous)

The current name is ambiguous. I also have a webserver for hosting my app, a push endpoint that some might consider a server, etc, so suggest renaming to clarify.
Copy link

vercel bot commented Jul 17, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
zero-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 17, 2025 10:51pm

@coryhouse coryhouse changed the title Update add-to-existing-project.mdx Rename server key in config to cacheServerUrl Jul 17, 2025
@aboodman
Copy link
Contributor

aboodman commented Aug 7, 2025

Good suggestion.

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

Successfully merging this pull request may close these issues.

2 participants