Re: [css-houdini-drafts] [css-paint-api]: APIs not exposed in Worklets

@bzbarsky point taken. I think Tab's point was more that browsers have to URL parse for worker resources anyway, so parsing URLs as a result of an action in a separate thread is not new (as opposed to parsing CSS as a result of an action in a separate thread, which is not currently a feature of the open web).

Coming back to the issue, the two viable options are:
(1) expose StyleValue objects with constructors that always throw
(2) expose StyleValue objects with constructors that work; however those requiring resource loading never get past the unloaded stage.

In neither case is CSS parse functionality exposed, based on WG consensus.

I lean towards (2) because it's better ergonomically for developers (less surprising). I will also assert that no weight is saved by having throwing constructors over functional constructors.

If URL parsing is problematic for Gecko then we can always move the parsing stage for resource values to the transition between unloaded and pending.

Are there any other considerations that should be taken into account?

-- 
GitHub Notification of comment by shans
Please view or discuss this issue at https://github.com/w3c/css-houdini-drafts/issues/237#issuecomment-318259254 using your GitHub account

Received on Thursday, 27 July 2017 05:03:20 UTC