> For the complete documentation index, see [llms.txt](https://jscula.gitbook.io/docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jscula.gitbook.io/docs/traversal/.prop.md).

# .prop()

Manipulate element attributes.

## `$(selector).prop(name, value?)`

* Getter: `$('#selector').prop(propertyName)`
* Setter (Single): `$('#selector').prop(propertyName, value)`
* Setter (Multiple): `$('#selector').prop({ propertyName: value, property2: value2 })`

#### Get property

```javascript
const checked = $('#checkbox').prop("checked");
```

#### Set property

```javascript
$('#checkbox').prop("checked", true);
```

#### Get Live State

```javascript
const isChecked = $('#notify').prop('checked');
```

#### Set live state

```javascript
$('#submitBtn').prop('disabled', true);
```

#### Set states via Object

```javascript
$('#settings').prop({ hidden: false, textContent: 'Settings Panel' });
```
