MCPcopy Create free account
hub / github.com/dailydotdev/apps / commandQuery

Function commandQuery

packages/shared/src/features/interests/commands.ts:60–64  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

58// A bare `/` returns an empty string, so callers must check for `undefined`
59// rather than for falsiness.
60export const commandQuery = (value: string): string | undefined => {
61 const match = /^\/([a-z-]*)$/.exec(value);
62
63 return match ? match[1] : undefined;
64};
65
66export const parseCommand = (
67 value: string,

Callers 2

commands.spec.tsFile · 0.90
AgentComposerFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected