You've already forked dynamic-badges-action
Add save svg-badge directly to gist
This adds the posibility of saving an SVG badge generated by the same shields.io dirictly to the gist. Instead of prepering a JSON file to be sent to their service, we use their library directly, which outputs an SVG file that we can save to the user’s gist. Filenames ending in `.svg` will use this library automatically. Additionally there is a major refactoring where the older `node:http` library has been swapped out for `fetch`. Also swap from node 16 to node 20 fixes #24
This commit is contained in:
22
node_modules/binary-search/binary-search.d.ts
generated
vendored
Normal file
22
node_modules/binary-search/binary-search.d.ts
generated
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
//Typescript type definition for:
|
||||
//https://github.com/darkskyapp/binary-search
|
||||
declare module 'binary-search' {
|
||||
|
||||
function binarySearch<A, B>(
|
||||
haystack: ArrayLike<A>,
|
||||
needle: B,
|
||||
comparator: (a: A, b: B, index?: number, haystack?: A[]) => any,
|
||||
// Notes about comparator return value:
|
||||
// * when a<b the comparator's returned value should be:
|
||||
// * negative number or a value such that `+value` is a negative number
|
||||
// * examples: `-1` or the string `"-1"`
|
||||
// * when a>b the comparator's returned value should be:
|
||||
// * positive number or a value such that `+value` is a positive number
|
||||
// * examples: `1` or the string `"1"`
|
||||
// * when a===b
|
||||
// * any value other than the return cases for a<b and a>b
|
||||
// * examples: undefined, NaN, 'abc'
|
||||
low?: number,
|
||||
high?: number): number; //returns index of found result or number < 0 if not found
|
||||
export = binarySearch;
|
||||
}
|
||||
Reference in New Issue
Block a user