mammoth-night-22453
05/27/2020, 8:14 PMconfig:
proj:data:
nonProductionStart: 10.1.0.0
productionStart: 10.2.0.0
stacks:
- name: Sandbox
peerConnectionName: peerConnectionId
stackName: org/Sandbox/mono
I can indeed follow the docs and get a JsonElement first, then get the sub-element as a string using something like
var data = Configuration.GetObject<JsonElement>("data");
var stacksAsString = data.GetProperty("stacks");
But what I really am trying to do is something like:
var stacks = Configuration.GetObject<List<StackReferenceInfo>>("data.stacks");
But, this does not appear to work. Is there no way to achieve this without jumping through the JsonElement hoop?
I have reviewed https://www.pulumi.com/docs/intro/concepts/config/#structured-configuration and it shows the JsonElement method - perhaps that's the only way?