You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat: support any result with any model or instances actions.
feat: support belongsTo, etc. (and support inverse guessing from it)
feat: warn log if model is used on action it is not attached to?
feat: add errors/logs with link to documentation to help issues resolving
feat: date transformers correctly specifying TZ provided or not (default UTC, TZ when suffixed such as toDateTimeTz, and a special toShiftedDate which do an epoch shift for date input resolution)
feat: experiment connection+type as generic on model, for strict typing with registry
docs: reorganize docs (no more "core concepts"/"digging deeper")
chore: remove useless type assertions (... as ...)
chore: use deprecated instead of internal
feat: provide origin snapshot in onUpdated etc. hooks
feat: better errors (specific for cachedOrFail, original for oneOrFail?)
feat: experiment composite attributes definition
Such as one call to define an attribute and a relation, like userId and user using a belongsTo factory.
feat: variadic action factory direct run
feat: dependencies using action instead of context
feat: real support for relations inside snapshots
Model instances snapshots should deeply lock state of relations (by snapshoting related instances too, instead of storing direct references). This would make the snapshot more realistic of a real state for the instance.
feat: serialization through snapshots instead of instances
Instances and relations serialization should use snapshots instead of instances. This would avoid being able to changes a record's values after creating the action instance but before running it.
feat: add object configuration for attributes and relations factories
feat: remove static methods from model
feat: remove arrayable variadic
chore: remove use of using to improve code readability
Won't fix
feat: define to null initial snapshot of new instances Because this would break partial change checking. Instead, an empty snapshot is creating without the use of takeSnapshot. That new behavior improve build size reduction.
Here are some ideas that might/should be implemented inside foscia:
Todo
load,loadMissing(and other, such asfreshandrefresh) using connectionslazyfunction to convert relation?)anyresult withanymodel or instances actions.toDateTimeTz, and a specialtoShiftedDatewhich do an epoch shift for date input resolution)... as ...)onUpdatedetc. hooksDone
cachedOrFail, original foroneOrFail?)Such as one call to define an attribute and a relation, like
userIdanduserusing abelongsTofactory.Model instances snapshots should deeply lock state of relations (by snapshoting related instances too, instead of storing direct references). This would make the snapshot more realistic of a real state for the instance.
Instances and relations serialization should use snapshots instead of instances. This would avoid being able to changes a record's values after creating the action instance but before running it.
usingto improve code readabilityWon't fix
feat: define toBecause this would break partial change checking. Instead, an empty snapshot is creating without the use ofnullinitial snapshot of new instancestakeSnapshot. That new behavior improve build size reduction.