-
Notifications
You must be signed in to change notification settings - Fork 106
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding the Web Bluetooth API feature #691
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving to allow merging after applying suggestions/rename.
@@ -0,0 +1,4 @@ | |||
name: bluetooth |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Everything called WebSomething or Web Something feels extra hard to pick a short name for, but in this case I think we should go with:
name: bluetooth | |
name: Web Bluetooth |
Web because it's a web version of a thing that exists outside the web and I've never seen the feature called just "Bluetooth". And capitalized Bluetooth because https://en.wikipedia.org/wiki/Bluetooth does that consistently, so I guess Bluetooth is a proper noun.
I think the identifier should be web-bluetooth
, matching web-animations
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No strong opinion from me on the ID for the feature. I thought we had a guideline against adding unnecessary prefixes like web, css, etc. though. Also, many of the web APIs start with "Web". So, we might end up with a lot of web-*.yaml
file.
That said, people do refer to it as Web Bluetooth, not just Bluetooth.
@Elchi3 what do you think? I need another perspective on this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have no strong feelings but it irked me before that when looking up things alphabetically you basically need to check B for Bluetooth and then again W for Web Bluetooth to find it. This problem becomes quite obvious when you look at https://developer.mozilla.org/en-US/docs/Web/API for example.
Also, we have webusb
, should that be web-usb
?
Ultimately, I would think, that no one has thought this through from a broader perspective. So I guess we have two paths going forward:
- either web-features comes up with strong guidelines on how to name web platform capabilities (and possibly bring that back to spec authors and others),
- or we don't want to shape existing and future naming and we use what is common today among web developers and what matches with the existing specs. This path will probably not lead to consistent names.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it irked me before that when looking up things alphabetically you basically need to check B for Bluetooth and then again W for Web Bluetooth to find it. This problem becomes quite obvious when you look at https://developer.mozilla.org/en-US/docs/Web/API for example.
I share your feelings here.
or we don't want to shape existing and future naming and we use what is common today among web developers and what matches with the existing specs. This path will probably not lead to consistent names.
This sounds appealing. We've always said that web-features should match how developers think about things. On the one hand, we have an opportunity of making web-features a shared language between browser makers and web developers, by coming up with unique IDs that everyone use to talk about the web. So it would feel good to get this right. But on the other hand, I don't see how we'd land on better names than the ones that have appeared organically and have been used for years in the ecosystem already.
So, I'm leaning towards adding the web-
prefix.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree this should have the web-
prefix and have said all I have to say about the topic in #548 (comment) :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
FWIW, I never imagined "name" would be the only name field, just the "conventional" (to web developers) one. I'd love to see—when relevant—short_name
(e.g., "Bluetooth", as here) or long_name
(e.g., "CSS Grid").
Co-authored-by: Philip Jägenstedt <[email protected]>
I've applied the naming suggestion but won't merge. @captainbrosset can you merge if you're happy with that? |
This depends on mdn/browser-compat-data#22627 which introduces the
web-features:bluetooth
tag to the corresponding BCD entries.