-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add google analytics #153
Add google analytics #153
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
}); | ||
|
||
if (!clientEnvRes.success) { | ||
// console.error(clientEnvRes.error.issues); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nit] do we need this?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should preserve this so that if other developers (assume we have other dev in our team) run the app on their local machine without proper .env
, an error will be thrown to let them know. Plus, we can catch the env error when testing before merging into prod.
@@ -1,7 +1,8 @@ | |||
import { cn } from "@/utils/cn"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
[nit] change the filename to camel case
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahh, that makes sense but actually this is kind of a frontend convention to name this file like this.
Ref:
Description
Add google analytics to track viewers and gain insight into users' behaviors.
Related Issue
Notes
zod
to parse environment variables.By doing so, if you have a misconfiguration in your
.env
(e.g. you forget to add some env vars), it will result in build-time error (for server config) or run-time error (for client-config). So that you can identify bugs when testing or building. It's better since the bug or error can be identified earlier before deploying to prod.Testing link: https://rec-f8x3073i7-recnet-542617e7.vercel.app/
TODO