Does anyone have experience running an expo/react-...
# help
a
Does anyone have experience running an expo/react-native application as part of the stack and injecting env variables in the expo build (in local dev and in CI when deploying etc.)
t
Ah we should probably expand
sst-env
to work with any set of outputs cc @Frank
f
With `StaticSite`’s environment prop, ie.
Copy code
new StaticSite(this, "ReactSite", {
  path: "path/to/src",
  environment: {
    API_URL: api.url,
  },
});
sst start
keeps a mapping of
API_URL
and the CFN output name. And after the stack is deployed, SST now knows the CFN output value. And when you run
sst-env
, it sets the environment variable
API_URL
with the output value.
With RN, what would be a way for SST to know what environment variable maps to which stack output?
s
Hi @Abdul Taleb - I'm coming up against the same problem. Did you come up with a strategy for this in the end? Would be great to get some insight into your solution.