breck7 / scrollsdk

Build on top of Scroll.
https://sdk.scroll.pub
379 stars 17 forks source link

ScrollParsers: add dependent types (or constraints) #148

Open breck7 opened 1 year ago

breck7 commented 1 year ago

Problem: be able to add better validation logic to both maintain clean data and also improve autocomplete.

Example situation: someone adds a line type visualLanguage to a tree, then perhaps certain lines would now be invalidated while others would be required/recommended.

Could be done with a 3rd category of thing (cell types, nodetypes, contraint types), or perhaps could start with a smaller surface area and grow to that.

ghost commented 1 year ago

Yes being explicit about which keys in a database are optional and which are not would be really nice. Right now if i am not mistaken databases keys can have syntax check for values but nothing more.