What problem are you facing?
Currently, we can access composition environment variables like:
env: {{ (index .context "apiextensions.crossplane.io/environment").key1 }}
However, this is too verbose and can be simplified with a helper function.
How could this Function help solve your problem?
To make it easier to access composition environment variables, we can have a helper function called getCompositionEnvVar. The interface might be like:
env: {{ getCompositionEnvVar . "key1" }}