---
title: "resetAttributes command"
description: "Use the resetAttributes command in Tiptap to reset a node's attributes to their default values. Learn more in our docs!"
canonical_url: "https://tiptap-docs.lin52025i.qzz.io/editor/api/commands/nodes-and-marks/reset-attributes"
---

# resetAttributes command

Use the resetAttributes command in Tiptap to reset a node's attributes to their default values. Learn more in our docs!

`resetAttributes` resets the specified attributes of a node or mark to their default values.

## Parameters

`typeOrName: string | NodeType | MarkType`

The name or type of the node or mark whose attributes should be reset.

`attributes: string | string[]`

A string or an array of strings that defines which attributes should be reset.

## Use the resetAttributes command

```js
// reset the style and class attributes on the currently selected paragraph nodes
editor.commands.resetAttributes('paragraph', ['style', 'class'])
```
