Azure / Azure/AppConfiguration-JavaScriptProvider

Custom secretResolver should return unknown/any type?

Aperta
#89 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
TypeScript
Stelle
18
Fork
13
Merge medio
1g 5h
PR unite (30g)
4

Descrizione

Use `KeyVaultOptions.secretResolver` to resolve the secret reference with customized logic, e.g. parse JSON string into an object.
```ts
/**
* Specifies the callback used to resolve key vault references that have no applied SecretClient.
* @param keyVaultReference The Key Vault reference to resolve.
* @returns The secret value.
*/
secretResolver?: (keyVaultReference: URL) => string | Promise;
```
Note: Here I think `secretResolver` should return `known` type instead of `string`, as we allow values of the config map to be any type.

_Originally posted by @Eskibear in https://github.com/Azure/AppConfiguration-JavaScriptProvider/issues/78#issuecomment-2287726906_

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.