peb
Version:
Peb.js makes JS easier
24 lines (20 loc) • 1.06 kB
Markdown
# Function `sel()`
**The last updated version of this function**: *3.1.0*
## Browser Support
| <img src="https://cdn.jsdelivr.net/gh/TechPot-Studio/svg-gallery/chrome.svg" width="30" /> | <img src="https://cdn.jsdelivr.net/gh/TechPot-Studio/svg-gallery/firefox.svg" width="30" /> | <img src="https://cdn.jsdelivr.net/gh/TechPot-Studio/svg-gallery/safari.svg" width="30" /> | <img src="https://cdn.jsdelivr.net/gh/TechPot-Studio/svg-gallery/opera.svg" width="30" /> | <img src="https://cdn.jsdelivr.net/gh/TechPot-Studio/svg-gallery/edge.svg" width="30" /> |
| :---: | :---: | :---: | :---: | :---: |
| 45 | 39 | 10 | 32 | 12 |
## Usage
```javascript
peb.sel(selector, itemIndex)
```
### ID Selector or `itemIndex`
[Reffer to `RElement`](cons-relement.md)
### And Others
#### `.forEach(callbackFn: function, startIndex: number)`
- `callbackFn` function parameter
| Parameter | Value Type | Description |
| :---: | :---: | :---: |
| currentItem | `RElement` | Reffer to single mode |
| index | `Number` | Index |
| collection | `RElementsCollection` | this |