# DenoAppResource.withDenoTask

- Module: [Aspire.Hosting.JavaScript](/reference/api/typescript/aspire.hosting.javascript.md)
- Defined on: [DenoAppResource](/reference/api/typescript/aspire.hosting.javascript/denoappresource.md)
- Version: `13.6.0`
- Kind: `method`

Selects the `deno task <taskName>` mode, running a task defined in `deno.json` instead of a script entrypoint. Permissions are defined by the task itself and are not emitted for this mode.

## Definition

```typescript
interface DenoAppResource {
  // ... omitted for brevity
  withDenoTask(taskName: string): DenoAppResource;
}
```

## Signature

```typescript
withDenoTask(taskName: string): DenoAppResource
```

## Parameters

- `taskName` (`string`)

## Returns

[DenoAppResource](/reference/api/typescript/aspire.hosting.javascript/denoappresource.md) `builder`

## Defined on

- [DenoAppResource](/reference/api/typescript/aspire.hosting.javascript/denoappresource.md) -- `handle`
