MCPcopy Create free account
hub / github.com/Kong/insomnia / parse

Method parse

packages/insomnia-scripting-environment/src/objects/urls.ts:62–65  ·  view source on GitHub ↗
(queryStr: string)

Source from the content-addressed store, hash-verified

60 static override _index = 'key';
61
62 static parse(queryStr: string) {
63 const params = new UrlSearchParams(queryStr);
64 return Array.from(params.entries()).map(entry => ({ key: entry[0], value: entry[1] }));
65 }
66
67 static parseSingle(paramStr: string, _idx?: number, _all?: string[]) {
68 const pairs = QueryParam.parse(paramStr);

Callers

nothing calls this directly

Calls 1

mapMethod · 0.80

Tested by

no test coverage detected