Splits a context string into its type and value components on the first occurrence of a delimiter.
This function parses strings like "folder:/path/to/folder" or "plugin:123" into an object
containing the type (the prefix before the first delimiter) and the value (the rest of the string).
If the path contains extra delimiters (e.g. "/pacs/queries/2601_AccessionNumber:12345678"), this
function correctly preserves those extra delimiters in the value component.
Parameters
context: unknown
The context string to be split. Must be a string.
delimiter: string = ":"
The delimiter character to split on. Defaults to ":".
Splits a context string into its type and value components on the first occurrence of a delimiter.
This function parses strings like "folder:/path/to/folder" or "plugin:123" into an object containing the type (the prefix before the first delimiter) and the value (the rest of the string). If the path contains extra delimiters (e.g. "/pacs/queries/2601_AccessionNumber:12345678"), this function correctly preserves those extra delimiters in the value component.