diff --git a/README.md b/README.md index d04a8d4..921aeb1 100644 --- a/README.md +++ b/README.md @@ -79,6 +79,10 @@ renderers: args: config1: true config2: 'xyz' + +# List of global args +globalArgs: + type: 'rtc' ``` ### Custom `Parser` and `Renderer` diff --git a/terra/src/base/terra_configs.ts b/terra/src/base/terra_configs.ts index 8f732f4..6587645 100644 --- a/terra/src/base/terra_configs.ts +++ b/terra/src/base/terra_configs.ts @@ -65,6 +65,13 @@ export class TerraConfigs { }); let renderers = (parsedYaml.renderers ?? []).map((p: any) => { + p.args = + parsedYaml.globalArgs || p.args + ? { + ...parsedYaml.globalArgs, + ...p.args, + } + : undefined; return p as TerraLoaderConfig; });