Intent to Implement and Ship: Web Bluetooth getAvailability()

155 views
Skip to first unread message

Ovidio Ruiz-Henríquez

unread,
Jun 14, 2019, 5:53:22 PM6/14/19
to blink-dev
Contact emails

Explainer
There is not an explainer because this is a very small change to an existing API.

Spec

Summary
Add the getAvailability() method described in the Web Bluetooth spec. The API returns a promise that resolves with true if the UA is running on a system that has a Bluetooth radio and false otherwise. The powered state of the Bluetooth radio does not influence the availability because developers the user can be asked to turn on the radio on with requestDevice().

Motivation
This API is useful for developers to know whether they should show UI for Web Bluetooth or not to the user. This is demonstrated in an example in the spec: https://webbluetoothcg.github.io/web-bluetooth/#example-getavailability.

Will this feature be supported on all six Blink platforms (Windows, Mac, Linux, ChromeOS, Android, and Android WebView)?
Feature will be supported on the platforms that currently implement Web Bluetooth. These are Windows, Mac, Linux, ChromeOS, and Android.

Is this feature fully tested by web-platform-tests?
Yes, I have a change in flight that implements this API and adds wpt tests: https://chromium-review.googlesource.com/c/chromium/src/+/1651516

Entry on the feature dashboard

Requesting approval to ship?
Yes

Philip Jägenstedt

unread,
Jun 19, 2019, 4:35:43 AM6/19/19
to Ovidio Ruiz-Henríquez, blink-dev
LGTM1, looks straightforward. Thanks for adding tests!

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/db7101c0-d5a9-401b-a0f0-f5814bda937d%40chromium.org.

Rick Byers

unread,
Jun 19, 2019, 8:56:27 AM6/19/19
to Philip Jägenstedt, odej...@chromium.org, blink-dev

Chris Harrelson

unread,
Jun 19, 2019, 10:20:54 AM6/19/19
to Rick Byers, Philip Jägenstedt, odej...@chromium.org, blink-dev

Joe Medley

unread,
Jun 20, 2019, 1:04:11 PM6/20/19
to odej...@chromium.org, Rick Byers, Chris Harrelson, Philip Jägenstedt, blink-dev
Ovidio,

Can you please create a new Chrome Status entry for this. You can use your summary and motivation text. FYI, this is the rough draft for the beta blog post when this eventually ships.
Joe Medley | Technical Writer, Chrome DevRel | jme...@google.com | 816-678-7195
If an API's not documented it doesn't exist.


Ovidio Ruiz-Henríquez

unread,
Jun 20, 2019, 2:20:00 PM6/20/19
to blink-dev, odej...@chromium.org, rby...@google.com, chri...@chromium.org, foo...@chromium.org
LGTM3

LGTM2

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+unsubscribe@chromium.org.

Joe Medley

unread,
Jun 21, 2019, 11:16:40 AM6/21/19
to Ovidio Ruiz-Henríquez, blink-dev, Rick Byers, Chris Harrelson, Philip Jägenstedt
Thank you.

Joe Medley | Technical Writer, Chrome DevRel | jme...@google.com | 816-678-7195
If an API's not documented it doesn't exist.

Hi Joe,

LGTM3

LGTM2

To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.

--
You received this message because you are subscribed to the Google Groups "blink-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to blink-dev+...@chromium.org.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/blink-dev/19db3e1c-e2fc-4be1-9e7e-db2d94e3bc0d%40chromium.org.
Reply all
Reply to author
Forward
0 new messages