---
# System prepended metadata

title: jQuery Each
tags: [jQuery]

---

---
tags: jQuery
---
###### tags: `jQuery`
# jQuery Each
### 遍歷A組件裡的所有子組件並複製標題 到B組件裡的所有子組件並依序在上方插入
```
$(".modAcTitle").each(function(i) {
    var $content = $('.content').eq(i);
    $(this).clone().prependTo($content);
});
```
![](https://i.imgur.com/snJmSpJ.png)
