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

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

Function: addInstance()

addInstance(instance, options): void

Defined in: packages/b2c-tooling-sdk/src/config/dw-json.ts:270

Add a new instance to dw.json.

If dw.json doesn't exist, creates a new one. If an instance with the same name already exists, throws an error.

Parameters

instance

DwJsonConfig

The instance configuration to add

options

AddInstanceOptions = {}

Options for adding

Returns

void

Throws

Error if instance with same name already exists

Released under the Apache-2.0 License.