Re: WebPlatform Browser Support phased approach?

Hi, Ronald–

On 11/1/13 1:47 PM, Ronald Mansveld wrote:
> It's OK. I've ran into Jean-Yves here at the London Office, and he
> brought me into contact with some of his american collegues. A bug has
> been filed to have the data be available as JSON, but it seems like
> their raw data are indeed the HTML-tables, so either way it would mean
> parsing that data. Either on their side, or on our side. There have been
> talks about extracting that data to machine-readable, but for now that's
> likely to be in the future.
>
> As for the MediaWiki extension: can you send me an example or spec of
> the precise JSON-formatting it expects?

Let me get back to you on that, but for now, here's the extension code 
itself:

 
https://github.com/webplatform/mediawiki/tree/master/extensions/CompaTables


> What might be a solution for now:
>
> - Use MediaWiki and JSON (and all benefits) when CIU/H5T data is available
> - Bypass MediaWiki and show the MDN table if no CIU/H5T data is available
>
> That way a lot of properties would still have the MW extension, just the
> entries that we don't have CIU/H5T data for would have to resort to the
> MDN-fallback.

I don't think that saves us any work. With this approach, we'd still 
need to output the raw table at some point, so whether it's MDN or 
CIU/H5T data doesn't matter.


> By simply looking at the analytics-data for the pages, we can always
> decide to manually provide MDN-JSON for pages with high request-rates,
> until a good parser has been written.
>
>
> I've come a long way parsing the MDN-data to JSON, the main problem is
> that some of the key-data is lumped together in 1 table-cell. So it's
> hard to extract that data in a correct way. I am trying however, just
> not sure about the right way to do so. (Part of the current solution is
> replacing a <br> with a textnode with a specific string, so I have a
> textual marker in the nodeValue where I can split the text on. Parsing
> this data really does feel like clutching at straws to get somewhere at
> times...

Very ugly :( I'm sorry you had to do that.

On the bright side, once this project is viable, nobody else will have 
to go through that pain. :)


> Let me know if the fallback-option would be feasible (I'm not too
> familiar with the current set-up of the servers etc, so I can't really
> make a call on that one), or that I should continue parsing the table to
> JSON.

Yeah, I still don't know, because I'm not that familiar with the 
technical details of how we'd do this alternate approach (inserting the 
table data into the pages directly).


Regards-
-Doug

Received on Friday, 1 November 2013 18:11:07 UTC