-
-
Notifications
You must be signed in to change notification settings - Fork 2
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
updates #19
updates #19
Conversation
Visit the preview URL for this PR (updated for commit ad0a1e3): https://aw-leaderboard--pr19-master-j9i375pi.web.app (expires Tue, 25 Jun 2024 11:59:05 GMT) 🔥 via Firebase Hosting GitHub Action 🌎 Sign: c41748b80c8db8604c9c431c363ccab703d858c1 |
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.
❌ Changes requested. Reviewed everything up to ad0a1e3 in 1 minute and 26 seconds
More details
- Looked at
610
lines of code in11
files - Skipped
1
files when reviewing. - Skipped posting
0
drafted comments based on config settings.
Workflow ID: wflow_8fqwUJxRIHzSPAL3
Want Ellipsis to fix these issues? Tag @ellipsis-dev
in a comment. You can customize Ellipsis with 👍 / 👎 feedback, review rules, user-specific overrides, quiet
mode, and more.
const colpath = "users"; | ||
const docpath = user.uid; | ||
const apiKey = genKey.generateApiKey(); | ||
const jsonObj = JSON.parse(`{"apiKey": "${apiKey}"}`); |
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.
Using JSON.parse
to create an object with a dynamic key is unnecessary and can be error-prone. Consider using object literal syntax directly:
const jsonObj = JSON.parse(`{"apiKey": "${apiKey}"}`); | |
const jsonObj = { apiKey: apiKey }; |
This change simplifies the code and avoids potential parsing errors.
Summary:
Updated Firestore rules, indexes, Firebase functions, and Vue components for improved authentication and data handling.
Key points:
README.md
to include initial setup instructions.functions/firestore.indexes.json
.functions/firestore.rules
.functions/package.json
to includegenerate-api-key
dependency.functions/src/index.ts
for user creation, deletion, API key management, data upload, and leaderboard updates.functions/src/types.ts
.functions/storage.rules
.src/components/Dashboard.vue
andsrc/components/Leaderboard.vue
to include authentication checks.src/firebase/data.ts
to include query parameters for fetching screen time data.Generated with ❤️ by ellipsis.dev