Developer Preview — This project is in active development. APIs may change. Provide feedback
Skip to content

@salesforce/b2c-tooling-sdk / config / getPopulatedFields

Function: getPopulatedFields()

getPopulatedFields(config): keyof NormalizedConfig[]

Defined in: packages/b2c-tooling-sdk/src/config/mapping.ts:181

Gets the list of fields that have values in a config.

Used for tracking which sources contributed which fields during configuration resolution.

Parameters

config

NormalizedConfig

The configuration to inspect

Returns

keyof NormalizedConfig[]

Array of field names that have non-empty values

Example

typescript
const config = { hostname: 'example.com', clientId: 'abc' };
const fields = getPopulatedFields(config);
// ['hostname', 'clientId']

All rights reserved.