-
Notifications
You must be signed in to change notification settings - Fork 44
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
Last changes before 1.0.0 #525
Conversation
WalkthroughThis pull request encompasses modifications across multiple files, focusing on environment variable naming, URL configurations, and asset path updates. The changes primarily involve renaming Changes
Possibly Related PRs
Suggested Reviewers
✨ Finishing Touches
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
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.
Actionable comments posted: 4
🧹 Nitpick comments (4)
backend/src/service/team.service.js (2)
31-32
: Error handling's looking a bit weak in the knees!The error message doesn't include the original error details, making debugging harder.
- throw new Error("Failed to create team"); + throw new Error(`Failed to create team: ${err.message}`);
36-36
: Extra blank line's making me lose myself!Remove the extra blank line to maintain consistent spacing.
frontend/src/utils/constants.js (1)
7-8
: Consider using environment variables for BASE_URLInstead of hardcoding URLs and toggling them through comments, consider using environment variables. This would make the configuration more maintainable and less error-prone.
-export const BASE_URL = 'localhost:3000'; -export const API_BASE_URL = `http://${BASE_URL}/api/`; - -//staging environment -// export const BASE_URL = 'onboarding-demo.bluewavelabs.ca'; -// export const API_BASE_URL = `https://${BASE_URL}/api/`; +export const BASE_URL = process.env.VITE_BASE_URL || 'localhost:3000'; +export const API_BASE_URL = `${process.env.NODE_ENV === 'production' ? 'https' : 'http'}://${BASE_URL}/api/`;README.md (1)
141-144
: Documentation needs some sauce!A few improvements needed in the environment variables section:
- Add language specification to the code block
- Provide more context about the BASE_URL usage
2. Backend Url -``` +```env BASE_URL - Backend urlAlso, consider adding more details about the BASE_URL: ```diff -BASE_URL - Backend url +BASE_URL - Backend url (e.g., 'localhost:3000' for local development or 'your-domain.com' for production)
🧰 Tools
🪛 markdownlint-cli2 (0.17.2)
143-143: Fenced code blocks should have a language specified
null(MD040, fenced-code-language)
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (2)
frontend/dist/index.html
is excluded by!**/dist/**
frontend/src/assets/icons/google-icon.svg
is excluded by!**/*.svg
📒 Files selected for processing (7)
README.md
(1 hunks)backend/src/controllers/team.controller.js
(1 hunks)backend/src/service/team.service.js
(1 hunks)frontend/src/components/Button/GoogleSignInButton/GoogleSignInButton.jsx
(1 hunks)frontend/src/templates/GuideMainPageTemplate/GuideMainPageComponents/List/ListItem/ListItem.jsx
(1 hunks)frontend/src/utils/constants.js
(1 hunks)frontend/vite.config.js
(1 hunks)
✅ Files skipped from review due to trivial changes (2)
- frontend/src/components/Button/GoogleSignInButton/GoogleSignInButton.jsx
- frontend/src/templates/GuideMainPageTemplate/GuideMainPageComponents/List/ListItem/ListItem.jsx
🧰 Additional context used
🪛 markdownlint-cli2 (0.17.2)
README.md
143-143: Fenced code blocks should have a language specified
null
(MD040, fenced-code-language)
⏰ Context from checks skipped due to timeout of 90000ms (1)
- GitHub Check: build (22.x)
🔇 Additional comments (1)
frontend/src/utils/constants.js (1)
3-4
: Yo! Security alert: Local environment using HTTP protocolThe local environment is using non-secure HTTP protocol. While this might be fine for local development, we should ensure this doesn't accidentally get deployed.
Let's check if there are any production builds using this configuration:
As title
[vite] hmr update /public/svg/utilityIcons.jsx Files in the public directory are served at the root path. Instead of /public/svg/utilityIcons.jsx, use /svg/utilityIcons.jsx.
Blocked request. This host ("onboarding-demo.bluewavelabs.ca") is not allowed. To allow this host, add "onboarding-demo.bluewavelabs.ca" to preview.allowedHosts in vite.config.js.