Schema generator pattern recognition #53
Labels
Module: Schemas
Issues pertaining to the @mcsb/schemas package.
Priority: Low
Issues which aren't critical, security-related, or significantly beneficial to users.
Type: Enhancement
Issues that are about a way in which the application can be improved.
Inventory data from the Hypixel API is structured as a map of numerical string keys (the inventory slot IDs) to the data within the corresponding inventory slot. Due to the amount of configurations, and the number of slots available, we instead use
patternProperties
for these.I'd like it if the schema generator was capable of automatically detecting inventory structures and replacing them with the pattern
^\d+$
. The catch to this would be there are other number-only keys that we may not want to include in this pattern, such as days of the week. We could look for "layout" or "inventory" in the key name.The text was updated successfully, but these errors were encountered: