(str: string)
| 33 | * @returns Numbers array. |
| 34 | */ |
| 35 | export function toNumbers(str: string) { |
| 36 | const matches = str.match(/-?(\d+(?:\.\d*(?:[eE][+-]?\d+)?)?|\.\d+)(?=\D|$)/gm) |
| 37 | |
| 38 | return matches ? matches.map(parseFloat) : [] |
| 39 | } |
| 40 | |
| 41 | /** |
| 42 | * String to matrix value. |
no outgoing calls
no test coverage detected
searching dependent graphs…