(s)
| 27 | |
| 28 | // parse all the ${xxx} to [xxx] |
| 29 | export const parseVariableFormat = (s) => { |
| 30 | const reg = /\${(.*?)}/g; |
| 31 | const result = []; |
| 32 | let match; |
| 33 | while ((match = reg.exec(s))) { |
| 34 | result.push(match[1]); |
| 35 | } |
| 36 | return uniq(result); |
| 37 | } |
| 38 | |
| 39 | |
| 40 | // json to {a="b",c="d"} |
no outgoing calls
no test coverage detected