summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/webapi/run/build.js4
-rw-r--r--packages/webapi/src/inheritance.ts (renamed from packages/webapi/src/inheritence.ts)2
-rw-r--r--packages/webapi/src/polyfill.ts8
3 files changed, 7 insertions, 7 deletions
diff --git a/packages/webapi/run/build.js b/packages/webapi/run/build.js
index 42571763a..63e17e84c 100644
--- a/packages/webapi/run/build.js
+++ b/packages/webapi/run/build.js
@@ -205,8 +205,8 @@ async function build() {
await rm('lib', { force: true, recursive: true })
await rm('exclusions.d.ts', { force: true, recursive: true })
await rm('exclusions.d.ts.map', { force: true, recursive: true })
- await rm('inheritence.d.ts', { force: true, recursive: true })
- await rm('inheritence.d.ts.map', { force: true, recursive: true })
+ await rm('inheritance.d.ts', { force: true, recursive: true })
+ await rm('inheritance.d.ts.map', { force: true, recursive: true })
await rm('polyfill.d.ts.map', { force: true, recursive: true })
await rm('polyfill.js.map', { force: true, recursive: true })
await rm('polyfill.js', { force: true, recursive: true })
diff --git a/packages/webapi/src/inheritence.ts b/packages/webapi/src/inheritance.ts
index f3b1476ae..713c24928 100644
--- a/packages/webapi/src/inheritence.ts
+++ b/packages/webapi/src/inheritance.ts
@@ -1,4 +1,4 @@
-export const inheritence = {
+export const inheritance = {
CSSStyleSheet: 'StyleSheet',
CustomEvent: 'Event',
DOMException: 'Error',
diff --git a/packages/webapi/src/polyfill.ts b/packages/webapi/src/polyfill.ts
index 0eb4794d4..13ad0eb10 100644
--- a/packages/webapi/src/polyfill.ts
+++ b/packages/webapi/src/polyfill.ts
@@ -83,7 +83,7 @@ import {
} from './ponyfill'
import { exclusions } from './exclusions'
-import { inheritence } from './inheritence'
+import { inheritance } from './inheritance'
export { pathToPosix } from './lib/utils'
export {
@@ -288,10 +288,10 @@ export const polyfill = (target: any, options?: PolyfillOptions) => {
if (excludeOptions.has(name)) continue
// skip WebAPIs that do not extend other WebAPIs
- if (!Object.hasOwnProperty.call(inheritence, name)) continue
+ if (!Object.hasOwnProperty.call(inheritance, name)) continue
const Class = target[name]
- const Super = target[inheritence[name as keyof typeof inheritence]]
+ const Super = target[inheritance[name as keyof typeof inheritance]]
// skip WebAPIs that are not available
if (!Class || !Super) continue
@@ -299,7 +299,7 @@ export const polyfill = (target: any, options?: PolyfillOptions) => {
// skip WebAPIs that are already inherited correctly
if (Object.getPrototypeOf(Class.prototype) === Super.prototype) continue
- // define WebAPIs inheritence
+ // define WebAPIs inheritance
Object.setPrototypeOf(Class.prototype, Super.prototype)
}