https://pulumi.com logo
Title
c

calm-horse-33012

02/09/2023, 10:34 PM
Hey, when writing Dynamic Providers, I found it a bit cumbersome to duplicate my Input definition with a version that takes a
pulumi.Input<T>
of all fields, and I noticed that there is even a utility method in
output.ts
,
Lifted<T>
that can lift a whole structure into one that contains
pulumi.Output<T>
, I think it could be nice to have a similar utility type for
pulumi.Input<T>
? For now I've made my own, but I'm sure I won't be the last person to want something like this. 🙂
You could even make
pulumi.dynamic.Resource
generic and make it lift the generic type automatically, making it a more seamless experience to write dynamic providers, since you get to avoid duplicating your input type definition sprinkled with
pulumi.Input<T>
. Sample of what an implementation could look like (simplified, doesn't support nested object, and isn't backwards compatible):
b

billowy-army-68599

02/10/2023, 12:08 AM
This sounds great! Could you file an issue?