# X25519.engine

Compiles WASM implementations of selected [`X25519`](/api/X25519) primitives, without installing them.

Random key generation remains on Ox's default implementation.

## Imports

:::code-group
```ts [Named]
import { X25519 } from 'ox/wasm'
```

```ts [Entrypoint]
import * as X25519 from 'ox/wasm/X25519'
```
:::

## Examples

```ts twoslash
// @noErrors
import { Engine } from 'ox'
import { X25519 } from 'ox/wasm'

await Engine.install({ X25519: X25519.engine() })

X25519.getPublicKey({ privateKey: '0x...' })
```

## Definition

```ts
function engine(): Promise<engine.ReturnType>
```

**Source:** [src/wasm/X25519.ts](https://github.com/wevm/ox/blob/main/src/wasm/X25519.ts#L31)

## Return Type

The WASM implementation of part of the `X25519` slot.

`Promise<engine.ReturnType>`
