---
id: fast-foundation.container.registertransformer
title: Container.registerTransformer() method
hide_title: true
---
<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[@microsoft/fast-foundation](./fast-foundation.md) &gt; [Container](./fast-foundation.container.md) &gt; [registerTransformer](./fast-foundation.container.registertransformer.md)

## Container.registerTransformer() method

Registers a transformer with the container for the specified key.

<b>Signature:</b>

```typescript
registerTransformer<K extends Key, T = K>(key: K, transformer: Transformer<T>): boolean;
```

## Parameters

|  Parameter | Type | Description |
|  --- | --- | --- |
|  key | K | The key to resolved to register the transformer with. |
|  transformer | Transformer&lt;T&gt; | The transformer to register. |

<b>Returns:</b>

boolean
