<!--
{
  "availability" : [
    "iOS: 16.0.0 -",
    "iPadOS: 16.0.0 -",
    "macCatalyst: 16.0.0 -",
    "tvOS: 16.0.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "UIKit",
  "identifier" : "/documentation/UIKit/NSTextListElement/init(children:textList:nestingLevel:)",
  "metadataVersion" : "0.1.0",
  "role" : "Initializer",
  "symbol" : {
    "kind" : "Initializer",
    "modules" : [
      "UIKit"
    ],
    "preciseIdentifier" : "c:objc(cs)NSTextListElement(cm)textListElementWithChildElements:textList:nestingLevel:"
  },
  "title" : "init(children:textList:nestingLevel:)"
}
-->

# init(children:textList:nestingLevel:)

Creates a text list element with the list elements and nesting level you provide.

```
convenience init?(children: [NSTextListElement], textList: NSTextList, nestingLevel: Int)
```

## Parameters

`children`

An array of [`NSTextListElement`](/documentation/UIKit/NSTextListElement) elements.

`textList`

The [`NSTextList`](/documentation/UIKit/NSTextList) to add elements to.

`nestingLevel`

An integer value that describes the level of nesting of these elements.

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)