anyone try this out: <https://github.com/sensedeep...
# random
t
k
I have not tried it, one issue I found with these sorts of libraries is that they never have all the stuff you need and some pattern you are using won’t work 😂 I ended up doing my own thing that makes the code super complicated and fragile 😞 and I am also searching for a good solution (I will check out this repo also) because I want the code to be more readable and easier to maintain
t
I actually love dynamodb-toolbox it's been incredible at implementing singletable design
onetable looks very similar so I want to try it out
k
One thing I did not like about dynamo-toolbox is that you can’t use the same attributes with multiple gsi’s at least not without writing the core yourself
t
I think you can
You can specify a default: attr => string function in your gsi that references whatever attributes you need
I did this recently
My main issue with dynamo toolbox (and maybe I'm using it wrong) is that for
query
I have to manualy build my primary key. I was looking for a function that could generate it given the attributes
k
Yep and use the onUpdate to update them when something changes, but I would love to not have to write the logic inside of the default
t
Another thing about onetable (which is coming in v4 of toolbox) is it uses generics to create types for your schemas
Really need that
k
Yes very much needed
t
I tried it but the typing was no way near as good as I would like it to be
k
@Thomas Ankcorn what did you end up using
t
I hope one day either prisma supports dynamodb, or somebody builds a good alternative where I can define my entities with a DSL and all the methods are strongly typed
We use dynomoose but are not happy with it for a few reasons, was trying a few alternatives but non stood out as good enough that switching was worth it as the project is massive
k
I found this one a while back but it was lacking some features that I need but it looks like it has a lot of activity going on https://github.com/tywalch/electrodb
c
Is migration support of much value? That seems like a big differentiator over toolbox
k
@thdxr just wanted to report back on this, I migrated my old implementation to onetable and it is really working great for me
t
oo nice. I had a friend try it out as well and seemed to have good things to report. Think I'm gonna switch over