addContextToSlug
Add a context (prefix) to slug if it doesn't already have one
Parameters
| Parameter | Type | Default | Notes |
|---|---|---|---|
| slug Required | string |
Hub API slug (with or without context) |
|
| context Required | string |
usually a portal's orgKey |
Returns
slug with context ({context}::{slug})
string
Function defined in packages/common/src/content/slugs.ts:45