--- id: bad87fee1348bd9aeda08826 title: Target Elements by id Using jQuery required: - link: 'https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.2.0/animate.css' challengeType: 6 videoUrl: '' localeTitle: Целевые элементы по id Использование jQuery --- ## Description
Вы также можете настраивать элементы по их атрибутам id. Сначала target3 элемент button с target3 с помощью селектора $("#target3") . Обратите внимание, что, как и в объявлениях CSS, вы вводите # перед именем id. Затем используйте .addClass() jQuery для добавления классов animated и fadeOut . Вот как вы делаете элемент button с id target6 исчезающим: $("#target6").addClass("animated fadeOut") .
## Instructions
## Tests
```yml tests: - text: Выберите элемент button с id target3 и используйте addClass() jQuery addClass() чтобы присвоить ей класс animated . testString: 'assert($("#target3").hasClass("animated"), "Select the button element with the id of target3 and use the jQuery addClass() function to give it the class of animated.");' - text: target3 элемент с идентификатором target3 и используйте addClass() jQuery addClass() чтобы присвоить ему класс fadeOut . testString: 'assert(($("#target3").hasClass("fadeOut") || $("#target3").hasClass("fadeout")) && code.match(/\$\(\s*.#target3.\s*\)/g), "Target the element with the id target3 and use the jQuery addClass() function to give it the class fadeOut.");' - text: 'Используйте только jQuery, чтобы добавить эти классы к элементу.' testString: 'assert(!code.match(/class.*animated/g), "Only use jQuery to add these classes to the element.");' ```
## Challenge Seed
```html

jQuery Playground

#left-well

#right-well

```
## Solution
```js // solution required ```