Skip to content
View as Markdown
View as Markdown

@salesforce/b2c-tooling-sdk / operations/debug / resolveBreakpointPath

Function: resolveBreakpointPath()

resolveBreakpointPath(input, sourceMapper, cartridges): string

Defined in: packages/b2c-tooling-sdk/src/operations/debug/resolve-path.ts:23

Resolve a user-provided file path to an SDAPI script_path.

Accepts:

  • Absolute local path: /Users/.../app_storefront/cartridge/controllers/Cart.js
  • Relative local path: ./cartridges/app_storefront/cartridge/controllers/Cart.js
  • Server path: /app_storefront/cartridge/controllers/Cart.js (passed through if not a local match)
  • Cartridge-name-prefixed: app_storefront/cartridge/controllers/Cart.js (prefixed with /)

Returns the SDAPI script_path (e.g. /app_storefront/cartridge/controllers/Cart.js). Throws with a helpful message if the path cannot be resolved.

Parameters

input

string

sourceMapper

SourceMapper

cartridges

CartridgeMapping[]

Returns

string

Released under the Apache-2.0 License.