Replies: 2 comments
-
Can you show what you're trying to do, please? |
Beta Was this translation helpful? Give feedback.
0 replies
-
Store can only have one |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm submitting a...
Question
I have an entity which has a database id which is the idKey i use for the store.
This makes it easy to get an entity by calling
getEntity(id)
But I also have a orderId which I would like to be able to quickly look up entities by.
I can look up the entity by looping through all the whole store but that seems very bad performance wise.
I thought about adding a orderIds: Map<OrderId, EntityId> to the root of the store and use that to look up the id.
But I'm not sure how to best keep that map updated.
How would you solve this?
Beta Was this translation helpful? Give feedback.
All reactions