mirror of
https://github.com/reactjs/react.dev.git
synced 2026-02-24 04:33:10 +00:00
Change tabIndex to match the types (string to number) (#3409)
Co-authored-by: Edward Baggott <edward.baggott@shellenergy.co.uk>
This commit is contained in:
@@ -130,7 +130,7 @@ As of React 16, any standard [or custom](/blog/2017/09/08/dom-attributes-in-reac
|
||||
React has always provided a JavaScript-centric API to the DOM. Since React components often take both custom and DOM-related props, React uses the `camelCase` convention just like the DOM APIs:
|
||||
|
||||
```js
|
||||
<div tabIndex="-1" /> // Just like node.tabIndex DOM API
|
||||
<div tabIndex={-1} /> // Just like node.tabIndex DOM API
|
||||
<div className="Button" /> // Just like node.className DOM API
|
||||
<input readOnly={true} /> // Just like node.readOnly DOM API
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user