MCPcopy Create free account
hub / github.com/SeleniumHQ/selenium / vendorFieldName

Function vendorFieldName

javascript/selenium-webdriver/generate_bidi.mjs:719–722  ·  view source on GitHub ↗
(name, namespace, taken)

Source from the content-addressed store, hash-verified

717// already scopes it. Its wire key is untouched. Keeps the namespace (`mozPermanent`) only if
718// dropping it would collide with a shared field on the same record.
719function vendorFieldName(name, namespace, taken) {
720 const stripped = name.replace(`${namespace}:`, '')
721 return taken.has(stripped) ? `${namespace}${pascalCase(stripped)}` : stripped
722}
723
724function pascalCase(word) {
725 return word.charAt(0).toUpperCase() + word.slice(1)

Callers 1

buildVendorModulesFunction · 0.85

Calls 2

pascalCaseFunction · 0.85
hasMethod · 0.45

Tested by

no test coverage detected