MCPcopy Create free account
hub / github.com/decaporg/decap-cms / urlFor

Method urlFor

packages/decap-cms-backend-forgejo/src/API.ts:209–220  ·  view source on GitHub ↗
(path: string, options: Options)

Source from the content-addressed store, hash-verified

207 }
208
209 urlFor(path: string, options: Options) {
210 const params = [];
211 if (options.params) {
212 for (const key in options.params) {
213 params.push(`${key}=${encodeURIComponent(options.params[key] as string)}`);
214 }
215 }
216 if (params.length) {
217 path += `?${params.join('&')}`;
218 }
219 return this.apiRoot + path;
220 }
221
222 parseResponse(response: Response) {
223 const contentType = response.headers.get('Content-Type');

Callers 2

requestMethod · 0.95
requestAllPagesMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected