JSON Schema Article

After a long time I finally published another article on the CodeProject.

Recently, I was more busy with paid work and FOSS than writing articles or giving talks. I am not sure if this will change soon, but at least a stroke of activity in these areas would be nice from time to time.

One article that I had in the making for quite some while now was about JSON schema. Unfortunately, it is quite outdated now. Since the time of writing (January 2017) two more specifications have been officially published (v6 and v7). The article only covers v3 and v4. I will try to update the article in the next couple of days. Furthermore, I will also add the source code that should be delivered together with it. The source code contains a small sample application in form of a WPF JSON Editor working against some schema. This was just use to back up the point that the most powerful combination is a partially generic UI with a JSON Schema definition in the background.

The advantage of creating a dedicated config editor seems obvious. The additional way to make it partially flexible (at least under the hood) does not seem so obvious. From personal experience, though, I can tell you that it offers really nice advantages, such as being able to have a consistent UI without thinking about particular scenarios. Likewise, the schema can be fairly easily updated (e.g., it could be placed on some server with local caching), which would also update the UI. No application update required. Last, but not least - maybe our configuration files appear in multiple versions. Having each version being associated with its own schema does not require any UI changes; it magically follows the possibilities of each file.

Personally, I found JSON Schema to be a tool that is needed on many occasions. In the web (open API specifications, TypeScript runtime evaluations, ...) or on standard applications (configuration files, ...).

Created .

References

Sharing is caring!