fix: make NEXT_PUBLIC_GTM_ID optional in client environment schema#172
fix: make NEXT_PUBLIC_GTM_ID optional in client environment schema#172MantisClone merged 2 commits intoRequestNetwork:mainfrom
Conversation
WalkthroughMade the client env var Changes
Sequence Diagram(s)sequenceDiagram
participant Browser
participant Layout
participant GTM as GoogleTagManager
Browser->>Layout: render app layout
alt NEXT_PUBLIC_GTM_ID defined
Layout->>GTM: mount(gtmId)
GTM-->>Layout: initialized
else NEXT_PUBLIC_GTM_ID undefined
Layout-->>Browser: skip mounting GTM
end
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes
Possibly related PRs
Suggested reviewers
Pre-merge checks and finishing touches❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
📜 Recent review detailsConfiguration used: CodeRabbit UI Review profile: CHILL Plan: Pro 📒 Files selected for processing (1)
🧰 Additional context used🧠 Learnings (1)📓 Common learnings⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
🔇 Additional comments (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
src/lib/env/client.mjs(1 hunks)
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: aimensahnoun
PR: RequestNetwork/easy-invoice#20
File: src/app/layout.tsx:34-34
Timestamp: 2025-02-19T14:23:43.558Z
Learning: In the Easy Invoice project, type assertion for the NEXT_PUBLIC_GTM_ID environment variable in Google Tag Manager integration is acceptable without additional runtime validation.
📚 Learning: 2025-02-19T14:23:43.558Z
Learnt from: aimensahnoun
PR: RequestNetwork/easy-invoice#20
File: src/app/layout.tsx:34-34
Timestamp: 2025-02-19T14:23:43.558Z
Learning: In the Easy Invoice project, type assertion for the NEXT_PUBLIC_GTM_ID environment variable in Google Tag Manager integration is acceptable without additional runtime validation.
Applied to files:
src/lib/env/client.mjs
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Build
- GitHub Check: Lint
MantisClone
left a comment
There was a problem hiding this comment.
@mayur1377 Please resolve the CodeRabbit comment. 🙏
|
Congratulations, your pull request has been merged! Thank you for your valuable contribution to Request Network. As a reminder, every merged PR is automatically entered into our Best PR Initiative, offering a quarterly prize of $500. Your work significantly supports our project's growth, and we encourage you to continue engaging with our community. Additionally, if you want to build or add crypto payments and invoicing features, explore how our API can reduce deployment time from months to hours while offering advanced features. Book a call with our expert to learn more and fast-track your development. |
Fixes #159
Summary by CodeRabbit
Chores
Bug Fixes