/** * Splits `string` into an array of its words. * * @category String * @param {string} [string=''] The string to inspect. * @param {RegExp|string} [pattern] The pattern to match words. * @returns {Array} Returns the words of `string`. * @example * * words('fred, barney, & pebbles') * // => ['fred', 'barney', 'pebbles'] * * words('fred, barney, & pebbles', /[^, ]+/g) * // => ['fred', 'barney', '&', 'pebbles'] */ export declare function words(string?: string, pattern?: RegExp | string): any; export default words;