I’m actually now wondering if implementing lazy migrations at the object level is madness or not.
e.g., myDatabase.someTable.someObject.latest().someProperty
Where the latest method ensures migrations for the object are lazily run as necessary.
Of course, that would complicate authoring quite a bit because if you forgot that latest() call things would go poof!
Hmm… if only there was a way to run an initiliser when using Object.create()… #JSDB already uses proxies so maybe?