Update snippet formatting

This commit is contained in:
Isabelle Viktoria Maciohsek
2020-09-06 14:20:45 +03:00
parent f384fc0ee3
commit 95746a843b
18 changed files with 60 additions and 71 deletions

View File

@ -9,7 +9,7 @@ Renders a slider element that uses a callback function to pass its value to the
- Render an `<input>` element of type `"range"` and the appropriate attributes, use the `callback` function in the `onChange` event to pass the value of the input to the parent.
```jsx
function Slider({ callback, disabled = false, readOnly = false }) {
const Slider = ({ callback, disabled = false, readOnly = false }) => {
return (
<input
type="range"
@ -18,7 +18,7 @@ function Slider({ callback, disabled = false, readOnly = false }) {
onChange={({ target: { value } }) => callback(value)}
/>
);
}
};
```
```jsx