- From: Lucas Garron via GitHub <sysbot+gh@w3.org>
- Date: Sat, 14 Sep 2024 00:21:31 +0000
- To: public-webauthn@w3.org
I 100% agree with the camelCase convention reasons, but just a technical note: > ```js > const { 'user-verifying-platform-authenticator' } = capabilities; > // SyntaxError: Unexpected token '}'. Expected a ':' prior to a named > // destructuring property. > ``` This is actually possible to do using a `:` (as suggested by the error message): ```js const { 'user-verifying-platform-authenticator': userVerifyingPlatformAuthenticator } = capabilities; ``` However, this is definitely not as ergonomic, more code to ship to the end-user for no good reason, and a less debuggable than if the exact same string is used to refer this the destructured value throughout the JSON and the code. -- GitHub Notification of comment by lgarron Please view or discuss this issue at https://github.com/w3c/webauthn/pull/1923#issuecomment-2350735016 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Saturday, 14 September 2024 00:21:32 UTC