JSON Schema property completion

Dear All,

    I'm aware that I can have JSON Schema's imported and I can then use Webstorm to validate JSON files. This is most excellent.

However, what I would like to be able to do is quite different and I was wondering if anyone could provide any ideas.

We have a large schema that defines a markup language. We build objects in node js modules like so.

var bob = { fields: [{name: 'bobsson', type: 'string'}, {name: 'missbob', type: 'specialtype'}], procedures: [] };

Now, the field definition is much more complex than this, simply put I would like to be able to find out properties that have been defined in the schema when I'm inside a fields object.

I'm guessing there's no simple fix, but could the bob object be marked up in some way to say "bob will adhere to schema bob-type.json" and then provide code completion for the properties in the schema?

If anyone could piont me at an addon that does something similar, I may be able to write my own so any thoughts most welcom.

Most grateful for any help.

Comment actions Permalink

Great idea, would be nice to have completion for json based on json schema same way XML has


Please sign in to leave a comment.