MCPcopy Create free account
hub / github.com/Devographics/Monorepo / parseEnvVariableArray

Function parseEnvVariableArray

results/node_src/helpers.ts:307–310  ·  view source on GitHub ↗
(variable = '')

Source from the content-addressed store, hash-verified

305 * APOLLO_SERVER_CORS_WHITELIST=http://localhost:5000,https://www.my-client.org
306 * => parse the string and makes it an array
307 * @param {*} variable Env array variables, with values separated by a comma (spaces allowed)
308 */
309export const parseEnvVariableArray = (variable = '') => {
310 if (!variable) return []
311 return variable.split(',').map(s => s.trim())
312}
313

Callers 1

getTranslationContextsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected