---
title: "resourceURL(name:)"
framework: tvmlkit
role: symbol
role_heading: Instance Method
path: "tvmlkit/tvinterfacecreating/resourceurl(name:)"
---

# resourceURL(name:)

Returns a URL for the given resource.

## Declaration

```swift
optional func resourceURL(name resourceName: String) -> URL?
```

## Parameters

- `resourceName`: A string that contains the name of the resource.

## Return Value

Return Value The URL associated with the resource name. The app must return nil if the event is not handled.

## Discussion

Discussion The resourceName parameter comes from a resource URL specified in certain elements. For example, badge src="resource://developer-resource"> contains the resource name, developer-resource.

## See Also

### Retrieving Resource Information

- [resourceImage(name:)](tvmlkit/tvinterfacecreating/resourceimage(name:).md)
