---
title: "wrapInList command"
description: "Use the wrapInList command in Tiptap to wrap a node in the current selection in a list. Learn more in our docs!"
canonical_url: "https://tiptap-docs.lin52025i.qzz.io/editor/api/commands/lists/wrap-in-list"
---

# wrapInList command

Use the wrapInList command in Tiptap to wrap a node in the current selection in a list. Learn more in our docs!

`wrapInList` will wrap a node in the current selection in a list.

## Parameters

`typeOrName: string | NodeType`

The type or name of the list node to wrap the selection in.

`attributes?: Record<string, any>`

The attributes that should be applied to the list. **This is optional.**

## Use the wrapInList command

```js
// wrap a paragraph in a bullet list
editor.commands.wrapInList('bulletList')
```
