(wire)
| 268 | const IDENTIFIER = /^[A-Za-z][A-Za-z0-9]*$/ |
| 269 | |
| 270 | function fieldName(wire) { |
| 271 | if (IDENTIFIER.test(wire)) return wire |
| 272 | const [head, ...rest] = wire.split(/[^A-Za-z0-9]+/).filter(Boolean) |
| 273 | if (!head) return wire |
| 274 | return head + rest.map((part) => part[0].toUpperCase() + part.slice(1)).join('') |
| 275 | } |
| 276 | |
| 277 | function projectField(prop) { |
| 278 | // A vendor-prefixed key (moz:allowPrivateBrowsing) keeps its wire form: extractVendor |
no test coverage detected