Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Typings for Bindings #345

Closed
ntziolis opened this issue Nov 4, 2020 · 1 comment
Closed

Typings for Bindings #345

ntziolis opened this issue Nov 4, 2020 · 1 comment

Comments

@ntziolis
Copy link

ntziolis commented Nov 4, 2020

Right now there are only bindings for a general context. Accessing input / output bindings is not typesafe:
https://docs.microsoft.com/en-us/azure/azure-functions/functions-bindings-storage-blob-trigger?tabs=javascript

context.bindings.myBlob

Instead it should be possible to provide a generic argument to the Context interface that holds a typed version of the bindings

const typedContext : Context<{
   myBlob: BlobTriggerIn
}>

Without these typings the typescript story of azure functions is incomplete.

@ejizba
Copy link
Contributor

ejizba commented May 24, 2023

We have improved these in the new programming model. Any further suggestions should be filed in this repo: https://github.com/Azure/azure-functions-nodejs-library

@ejizba ejizba closed this as completed May 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants