--- id: bad87fee1348bd9aec908855 title: 各要素に一意の id を付ける challengeType: 0 forumTopicId: 18191 dashedName: give-each-element-a-unique-id --- # --description-- また、jQuery を使用してそれぞれのボタンを一意の id でターゲットとして選択できるようにします。 `target1` から `target6` までの各ボタンに一意の id を付けてください。 `target1` から `target3` までを `#left-well` の中に入れ、`target4` から `target6` までを `#right-well` の中に入れてください。 # --hints-- `button` 要素に id `target1` を付けます。 ```js assert( $('#left-well').children('#target1') && $('#left-well').children('#target1').length > 0 ); ``` `button` 要素に id `target2` を付けます。 ```js assert( $('#left-well').children('#target2') && $('#left-well').children('#target2').length > 0 ); ``` `button` 要素に id `target3` を付けます。 ```js assert( $('#left-well').children('#target3') && $('#left-well').children('#target3').length > 0 ); ``` `button` 要素に id `target4` を付けます。 ```js assert( $('#right-well').children('#target4') && $('#right-well').children('#target4').length > 0 ); ``` `button` 要素に id `target5` を付けます。 ```js assert( $('#right-well').children('#target5') && $('#right-well').children('#target5').length > 0 ); ``` `button` 要素に id `target6` を付けます。 ```js assert( $('#right-well').children('#target6') && $('#right-well').children('#target6').length > 0 ); ``` # --seed-- ## --seed-contents-- ```html

jQuery Playground

#left-well

#right-well

``` # --solutions-- ```html

jQuery Playground

#left-well

#right-well

```