https://pulumi.com logo
#typescript
Title
# typescript
w

worried-engineer-33884

01/22/2020, 6:31 PM
How does
aws.Provider
have a
region
output, but TS throws:
Copy code
2339: Property 'region' does not exist on type 'Provider'.
a

acoustic-florist-12628

01/22/2020, 8:12 PM
Looking at
@pulumi/aws/provider.d.ts
, the aws.Provider class doesn't expose any of its values as properties. It does register its inputs/outputs in the checkpoint file, which is why region appears there (region is defined in the ProviderArgs interface for input). Unfortunately, in order to actually access these values from external TS code, they would need to be declared in the class. Depending on what you are trying to do, I believe
aws.config.region
can give you the region that is being used.