Dima Utkin
Dima Utkin
CCConvex Community
Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/10/2024 in #support-community
Feature Request: API for checking if query/mutation/action is loading
and there's a good post on Convex Stack about another classic issue of pure reactive systems https://stack.convex.dev/help-my-app-is-overreacting so, wrappers are very much needed sometimes
139 replies
CCConvex Community
Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/10/2024 in #support-community
Feature Request: API for checking if query/mutation/action is loading
default useQuery from convex/react won't be any of help in this case 🤷‍♂️
139 replies
CCConvex Community
Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/10/2024 in #support-community
Feature Request: API for checking if query/mutation/action is loading
true, the nature of the website\app is very important here. but i can hardly imagine creating a nice UX just for basic "navigate back to the previous page" experience, without utilizing some sort of a client-side cache(if we're talking SPA)
139 replies
CCConvex Community
Created by FleetAdmiralJakob 🗕 🗗 🗙 on 4/10/2024 in #support-community
Feature Request: API for checking if query/mutation/action is loading
@FleetAdmiralJakob 🗕 🗗 🗙 i'm pretty sure that having a (semi-)polished experience for a production app would require you to have tanstack-query as a wrapper for ConvexHttpClient or ConvexReactClient, imho, for majority of your queries
139 replies
CCConvex Community
Created by Var& on 11/30/2023 in #support-community
Get the count of the query without using collect()
Anything that remotely resembles CQRS pattern. When you have a flow of commands and events that trigger each other. Imagine you have a command like "create patient", after it's executed and an event "patient created" was emitted and persisted into a db, you might want to execute multiple different commands related to that event, establishing some defaults, setting some cron jobs, etc. You definitely can do that programmatically, but alternatively, db can become a source of truth and context for all the related actions you want to execute, following your app's business logic
22 replies
CCConvex Community
Created by Var& on 11/30/2023 in #support-community
Get the count of the query without using collect()
I'm really interested in a normal db-driven triggers, imho, they're the best feature of firestore, basically for any event-driven flows it's a must. I'll wait, I'm patient and i know how hard these things are to implement 🙂
22 replies
CCConvex Community
Created by Var& on 11/30/2023 in #support-community
Get the count of the query without using collect()
i was hoping to see triggers in Convex(which could be, theoretically, used for these kind of problems), and was promised they're coming, but it seems like it's not a high priority
22 replies
CCConvex Community
Created by Var& on 11/30/2023 in #support-community
Get the count of the query without using collect()
@ian firestore got count/sum/avg on client not that long ago, and it doesn't fetch all the document, of course 🙂
22 replies
CCConvex Community
Created by TripleSpeeder on 10/20/2023 in #support-community
Is there a way to get the object type from a db.get result?
maybe have a look at normalizeId
15 replies
CCConvex Community
Created by TripleSpeeder on 10/20/2023 in #support-community
Is there a way to get the object type from a db.get result?
15 replies
CCConvex Community
Created by TripleSpeeder on 10/20/2023 in #support-community
Is there a way to get the object type from a db.get result?
you can make a union of v.object and add a record type field, next to id, that would be more explicit, imho
15 replies
CCConvex Community
Created by ian on 4/21/2023 in #support-community
authorization support?
again, it's very "what's a <user>?" dependent issue to me. Right now, i'm working on a multi-tenant app(mostly on FE side), with rules from casl lib, and we're both empowered by this lib, but also somewhat limited by it in some of the cases, but in general, in works for us. i see this authZ system as: authN provider (with optional roles like planned in Clerk) <-> user in Convex with roles -> rules on entities in Convex db <-> optional per-user limits for working with entities in db. Like RBAC is top-level, and ABAC(?) is a nested, more granular level on top of role-based access rules. Still, i'm a rookie in this area 🙂
15 replies
CCConvex Community
Created by ian on 4/21/2023 in #support-community
authorization support?
@ian tbh, i have no idea, how this should work "in general", i've never implemented sophisticated enough access controls in any app i've worked on. what i have in mind as a "perfect" solution from the developer's point of view is smth like if can(userId, resource, action)... this is the pattern from permit.io service, which looks awesome, but have a list of downsides(especially, the pricing) but it also bring up a lot of questions... what if the DB is not the only thing you want to protect with these rules? what about calling other APIs, RPC calls to other parts of your infra, using features, etc.? My point is that, it might work if the target is feature-parity with Firebase, they do have a nice and straightforward way of declaring access rules for the DB. but is it enough for everyone? is it even a good idea to limit these rules to the DB level? What's a <user> if you don't use Firebase Auth? Lots of question there. I don't know if there is a universal solution 🤷
15 replies