Generating skeleton JSON for APIs in BCD


(Eric Shepherd) #1

Anyone game to try creating a tool that takes as input the WebIDL for an API interface and outputs a skeleton JSON file for adding it to BCD?

There are a few WebIDL parsers available on npm that would provide almost everything that’s needed. Since all you need are the names of attributes and methods, and no other information, you can spit out the framework quite easily.

For each item, simply use null as the value for the support version, indicating “unknown”. Then we can use the tool to generate the structure of the JSON and all we have to do is go in and fill in the details.

Sheppy


(Eric Shepherd) #2

OK, I’m giving it a shot to create this. I think it will save a ton of time over the long haul.

Sheppy


(Chris Mills) #3

Nice, thanks sheppy! And sorry for not commenting earlier. I only just saw this thread.