# AddDenoTask

- Module: [CommunityToolkit.Aspire.Hosting.Deno](/reference/api/go/communitytoolkit.aspire.hosting.deno.md)
- Version: `13.6.1`
- Kind: `method`
- Defined on: `DistributedApplicationBuilder`
- Source: [GitHub](https://github.com/CommunityToolkit/Aspire/tree/d9c2addac6f527ef2e33712d290b84574b455a3b)

Adds a Deno task to the distributed application builder

## Definition

```go
func (DistributedApplicationBuilder) AddDenoTask(
    name string,
    options ...*AddDenoTaskOptions,
) DenoAppResource
```

## Parameters

- `name` (`string`) -- The name of the resource.
- `options` (`...*AddDenoTaskOptions`) -- optional settings, see [Options](#options)

## Options

Optional parameters are passed in a trailing `options ...*AddDenoTaskOptions` argument.

- `WorkingDirectory` (`*string`) -- The working directory to use for the command. If null, the working directory of the current process is used.
- `TaskName` (`*string`) -- The deno task to execute. Defaults to "start".
- `Args` (`[]string`) -- The arguments to pass to the command.

## Returns

[`DenoAppResource`](/reference/api/go/communitytoolkit.aspire.hosting.deno/denoappresource.md) -- A reference to the `IResourceBuilder`.

Returns a handle; failures surface later via `Err()`.

## Applies to

- `DistributedApplicationBuilder`
