---
title: "subscript(_:as:)"
framework: usdkit
role: symbol
role_heading: Instance Subscript
platforms: [iOS 27.0+, iPadOS 27.0+, Mac Catalyst 27.0+, macOS 27.0+, tvOS 27.0+, visionOS 27.0+]
path: "usdkit/usdprim/subscript(_:as:)-1frls"
---

# subscript(_:as:)

Access or modify the value of a named attribute on this prim.

## Declaration

```swift
subscript<T>(attributeName: USDToken, as type: T.Type) -> T? where T : USDPrim.Attribute.Value { get nonmutating set }
```
