@n3okill/utils
Version:
Many javascript helpers
9 lines (8 loc) • 335 B
TypeScript
/**
* Return `false` if buffer is unbalanced, or
* an Array<BalancedDataBuffer> mapping the chunks of 'open' and 'close' locations, if input buffer is unbalanced will return empty
* @param input
* @param open
* @param close
*/
export declare function balanced(input: Buffer, open?: string, close?: string): boolean | number[][];