(keypath)
| 43 | } |
| 44 | |
| 45 | function dottedIdentifier(keypath) { |
| 46 | const path = keypath.split('.'); |
| 47 | let out; |
| 48 | for (let i=0; i<path.length; i++) { |
| 49 | const ident = propertyName(path[i]); |
| 50 | out = i===0 ? ident : t.memberExpression(out, ident); |
| 51 | } |
| 52 | return out; |
| 53 | } |
| 54 | |
| 55 | function patternStringToRegExp(str) { |
| 56 | const parts = str.split('/').slice(1); |
no test coverage detected
searching dependent graphs…