---
lang: en
title: 'API docs: context.contextobserverfn'
keywords: LoopBack 4.0, LoopBack 4
sidebar: lb4_sidebar
permalink: /doc/en/lb4/apidocs.context.contextobserverfn.html
---

<!-- Do not edit this file. It is automatically generated by API Documenter. -->

[Home](./index.md) &gt; [@loopback/context](./context.md) &gt; [ContextObserverFn](./context.contextobserverfn.md)

## ContextObserverFn type

Listen on `bind`<!-- -->, `unbind`<!-- -->, or other events

<b>Signature:</b>

```typescript
export declare type ContextObserverFn = (eventType: ContextEventType, binding: Readonly<Binding<unknown>>, context: Context) => ValueOrPromise<void>;
```

