(obj, ignores = [])
| 23 | } |
| 24 | |
| 25 | export function stringifyQuery(obj, ignores = []) { |
| 26 | const qs = []; |
| 27 | |
| 28 | for (const key in obj) { |
| 29 | if (ignores.indexOf(key) > -1) { |
| 30 | continue; |
| 31 | } |
| 32 | |
| 33 | qs.push( |
| 34 | obj[key] |
| 35 | ? `${encode(key)}=${encode(obj[key])}`.toLowerCase() |
| 36 | : encode(key) |
| 37 | ); |
| 38 | } |
| 39 | |
| 40 | return qs.length ? `?${qs.join('&')}` : ''; |
| 41 | } |
| 42 | |
| 43 | export const isAbsolutePath = cached(path => { |
| 44 | return /(:|(\/{2}))/g.test(path); |
no outgoing calls
no test coverage detected
searching dependent graphs…