I have summarized and compiled a list of React.JS best practices from various sources across the internet.
Предположим, у меня есть список айтемов, где у каждого, например, есть кнопка удаления. По нажатию на кнопку просто вызывается какая-то функция, которая работает с backend API.
function ListItem({ data }) {
return (
<li className="list-item">
{/* ... */}
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.rounded-corners-gradient-borders { | |
width: 300px; | |
height: 80px; | |
border: double 4px transparent; | |
border-radius: 80px; | |
background-image: linear-gradient(white, white), radial-gradient(circle at top left, #f00,#3020ff); | |
background-origin: border-box; | |
background-clip: content-box, border-box; | |
} |