web-platform-dx / web-features

Exploring how to present Web platform features adoptability
https://web-platform-dx.github.io/web-features/
Apache License 2.0
378 stars 74 forks source link

Publish plain JSON artifacts "live" #1860

Open ddbeck opened 1 month ago

ddbeck commented 1 month ago

We publish a next-tagged web-features pre-release on npm on each push to main (you install it with npm install web-features@next). If you want the latest web-features data, this is convenient, unless you're not an npm user.

We ought to publish the plain JSON files on the web-features site, so that it's possible to do something like curl https://web-platform-dx.github.io/web-features/downloads/next/data.json (and likewise for the extended JSON and JSON Schema artifacts).

tabatkins commented 1 month ago

Yup, I was about to ask about this in #1853. My use-case is having the bikeshed-data project (which runs about 100 times/day) fetch the data, then digest it into the form that Bikeshed users will actually download. This is a Python project, and just pings a bunch of public URLs for its data sources, including currently the CanIUse and MDN data; I was hoping I could use this same strategy for Web Features data.

Note that CanIUse just has one giant JSON blob; MDN has a top-level directory listing, and then I download all the individual files it mentions. I can handle either way, whatever's convenient for y'all; all I need is a dependable way to get all the data without manual intervention.

ddbeck commented 1 month ago

@tabatkins we now have a continuously-updated release at https://github.com/web-platform-dx/web-features/releases/tag/next, so you can get assets via a stable URL like https://github.com/web-platform-dx/web-features/releases/download/next/data.extended.json.

Is this what you were looking for? Anything not nice or could be better about this?

tabatkins commented 3 weeks ago

Sorry, circling back just to say that I haven't tested this yet; I'll try to start ingesting this data next month and report back.