# IncrementalSyntaxEngine

Source: /tuil/docs/reference/packages/code/api/incremental-syntax-engine
Locale: en

interface exported by @mwillbanks/tuil-code.



{/* Generated by tooling/docs/generate-reference.ts. */}

## interface [#interface]

Public interface exported by `@mwillbanks/tuil-code`.

```ts
export interface IncrementalSyntaxEngine {
  parse(
    source: string,
    previous: IncrementalSyntaxTree | undefined,
    signal: AbortSignal,
  ): IncrementalSyntaxTree | Promise<IncrementalSyntaxTree>;
  dispose?(): void;
}
```

## Members [#members]

| Member    | Type                                                                                                                                             | Required | Description                                                                                                                                                                            | Related types                                                                        |
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------ | -------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------ |
| `parse`   | `(source: string, previous: IncrementalSyntaxTree \| undefined, signal: AbortSignal) => IncrementalSyntaxTree \| Promise<IncrementalSyntaxTree>` | Yes      | The `parse` member uses the `(source: string, previous: IncrementalSyntaxTree \| undefined, signal: AbortSignal) => IncrementalSyntaxTree \| Promise<IncrementalSyntaxTree>` contract. | [`IncrementalSyntaxTree`](/tuil/docs/reference/packages/code/api/incremental-syntax-tree) |
| `dispose` | `(() => void) \| undefined`                                                                                                                      | No       | The `dispose` member uses the `(() => void) \| undefined` contract.                                                                                                                    | —                                                                                    |

## Parameters [#parameters]

This declaration has no public members.

## Returns [#returns]

This declaration does not return a value.

## Throws [#throws]

No thrown errors are documented for this declaration.

## Related types [#related-types]

* [`IncrementalSyntaxTree`](/tuil/docs/reference/packages/code/api/incremental-syntax-tree)

## Source [#source]

[View the secondary source reference](https://github.com/mwillbanks/tuil/blob/main/packages/code/src/index.ts)

## Package [#package]

[@mwillbanks/tuil-code](/tuil/docs/reference/packages/code)
