Skip to content

🎥 Make videos programmatically with React

let's go

Jonny Burger7e1820ca4dc7
diff --git a/packages/player-example/src/App.tsx b/packages/player-example/src/App.tsx
index 1474337191..234f27e369 100644
--- a/packages/player-example/src/App.tsx
+++ b/packages/player-example/src/App.tsx
@@ -19,6 +19,9 @@ export default function App() {
ref.current?.addEventListener('seeked', (e) => {
setLogs((l) => [...l, 'seeked to ' + e.detail.frame + ' ' + Date.now()]);
});
+ ref.current?.addEventListener('ended', (e) => {
+ setLogs((l) => [...l, 'ended ' + Date.now()]);
+ });
}, []);
return (
diff --git a/packages/player/package-lock.json b/packages/player/package-lock.json
index dfca69c2e4..04571eaf0f 100644
--- a/packages/player/package-lock.json
+++ b/packages/player/package-lock.json
@@ -827,25 +827,22 @@
}
},
"@jonny/eslint-config": {
- "version": "2.1.225",
- "resolved": "https://registry.npmjs.org/@jonny/eslint-config/-/eslint-config-2.1.225.tgz",
- "integrity": "sha512-c6ukPCzyiRU0vA9h50M5nrqXT/Bzn7Z0vWrbts7M0JKvrwAQrHTt3h1CkyLS/odTAPywVa1SyJEatsQ+pFHsxA==",
+ "version": "2.1.233",
+ "resolved": "https://registry.npmjs.org/@jonny/eslint-config/-/eslint-config-2.1.233.tgz",
+ "integrity": "sha512-whOwsCDeE4MGSB7DEeQ9Cp1XkYRLbq3DBNgZ9ptxPu4exJWPk9vDMNNncFBp4X0teg19MGK93aUbt9VWSmQVUg==",
"requires": {
- "@typescript-eslint/eslint-plugin": "^4.18.0",
- "@typescript-eslint/parser": "^4.18.0",
+ "@typescript-eslint/eslint-plugin": "^4.22.0",
+ "@typescript-eslint/parser": "^4.22.0",
"babel-eslint": "10.1.0",
- "eslint-config-prettier": "^6.15.0",
- "eslint-config-xo": "^0.29.1",
- "eslint-config-xo-react": "^0.23.0",
+ "eslint-config-prettier": "^8.3.0",
+ "eslint-config-xo": "^0.36.0",
+ "eslint-config-xo-react": "^0.25.0",
"eslint-plugin-10x": "^1.5.0",
- "eslint-plugin-ava": "^10.5.0",
- "eslint-plugin-fp": "^2.3.0",
- "eslint-plugin-import": "^2.22.1",
- "eslint-plugin-promise": "^4.3.1",
- "eslint-plugin-react": "^7.22.0",
+ "eslint-plugin-promise": "^5.1.0",
+ "eslint-plugin-react": "^7.23.2",
"eslint-plugin-react-hooks": "^4.2.0",
- "eslint-plugin-react-native-normalized": "^1.0.4",
- "eslint-plugin-ts-exports": "^1.2.4"
+ "eslint-plugin-react-native-normalized": "^1.1.1",
+ "eslint-plugin-ts-exports": "^1.2.5"
}
},
"@nodelib/fs.scandir": {
@@ -1084,11 +1081,6 @@
"resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.7.tgz",
"integrity": "sha512-cxWFQVseBm6O9Gbw1IWb8r6OS4OhSt3hPZLkFApLjM8TEXROBuQGLAH2i2gZpcXdLBIrpXuTDhH7Vbm1iXmNGA=="
},
- "@types/json5": {
- "version": "0.0.29",
- "resolved": "https://registry.npmjs.org/@types/json5/-/json5-0.0.29.tgz",
- "integrity": "sha1-7ihweulOEdK4J7y+UnC86n8+ce4="
- },
"@types/minimatch": {
"version": "3.0.4",
"resolved": "https://registry.npmjs.org/@types/minimatch/-/minimatch-3.0.4.tgz",
@@ -1161,12 +1153,12 @@
"integrity": "sha512-37RSHht+gzzgYeobbG+KWryeAW8J33Nhr69cjTqSYymXVZEN9NbRYWoYlRtDhHKPVT1FyNKwaTPC1NynKZpzRA=="
},
"@typescript-eslint/eslint-plugin": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.19.0.tgz",
- "integrity": "sha512-CRQNQ0mC2Pa7VLwKFbrGVTArfdVDdefS+gTw0oC98vSI98IX5A8EVH4BzJ2FOB0YlCmm8Im36Elad/Jgtvveaw==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-4.22.0.tgz",
+ "integrity": "sha512-U8SP9VOs275iDXaL08Ln1Fa/wLXfj5aTr/1c0t0j6CdbOnxh+TruXu1p4I0NAvdPBQgoPjHsgKn28mOi0FzfoA==",
"requires": {
- "@typescript-eslint/experimental-utils": "4.19.0",
- "@typescript-eslint/scope-manager": "4.19.0",
+ "@typescript-eslint/experimental-utils": "4.22.0",
+ "@typescript-eslint/scope-manager": "4.22.0",
"debug": "^4.1.1",
"functional-red-black-tree": "^1.0.1",
"lodash": "^4.17.15",
@@ -1186,50 +1178,50 @@
}
},
"@typescript-eslint/experimental-utils": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.19.0.tgz",
- "integrity": "sha512-9/23F1nnyzbHKuoTqFN1iXwN3bvOm/PRIXSBR3qFAYotK/0LveEOHr5JT1WZSzcD6BESl8kPOG3OoDRKO84bHA==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/experimental-utils/-/experimental-utils-4.22.0.tgz",
+ "integrity": "sha512-xJXHHl6TuAxB5AWiVrGhvbGL8/hbiCQ8FiWwObO3r0fnvBdrbWEDy1hlvGQOAWc6qsCWuWMKdVWlLAEMpxnddg==",
"requires": {
"@types/json-schema": "^7.0.3",
- "@typescript-eslint/scope-manager": "4.19.0",
- "@typescript-eslint/types": "4.19.0",
- "@typescript-eslint/typescript-estree": "4.19.0",
+ "@typescript-eslint/scope-manager": "4.22.0",
+ "@typescript-eslint/types": "4.22.0",
+ "@typescript-eslint/typescript-estree": "4.22.0",
"eslint-scope": "^5.0.0",
"eslint-utils": "^2.0.0"
}
},
"@typescript-eslint/parser": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.19.0.tgz",
- "integrity": "sha512-/uabZjo2ZZhm66rdAu21HA8nQebl3lAIDcybUoOxoI7VbZBYavLIwtOOmykKCJy+Xq6Vw6ugkiwn8Js7D6wieA==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-4.22.0.tgz",
+ "integrity": "sha512-z/bGdBJJZJN76nvAY9DkJANYgK3nlRstRRi74WHm3jjgf2I8AglrSY+6l7ogxOmn55YJ6oKZCLLy+6PW70z15Q==",
"requires": {
- "@typescript-eslint/scope-manager": "4.19.0",
- "@typescript-eslint/types": "4.19.0",
- "@typescript-eslint/typescript-estree": "4.19.0",
+ "@typescript-eslint/scope-manager": "4.22.0",
+ "@typescript-eslint/types": "4.22.0",
+ "@typescript-eslint/typescript-estree": "4.22.0",
"debug": "^4.1.1"
}
},
"@typescript-eslint/scope-manager": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.19.0.tgz",
- "integrity": "sha512-GGy4Ba/hLXwJXygkXqMzduqOMc+Na6LrJTZXJWVhRrSuZeXmu8TAnniQVKgj8uTRKe4igO2ysYzH+Np879G75g==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/scope-manager/-/scope-manager-4.22.0.tgz",
+ "integrity": "sha512-OcCO7LTdk6ukawUM40wo61WdeoA7NM/zaoq1/2cs13M7GyiF+T4rxuA4xM+6LeHWjWbss7hkGXjFDRcKD4O04Q==",
"requires": {
- "@typescript-eslint/types": "4.19.0",
- "@typescript-eslint/visitor-keys": "4.19.0"
+ "@typescript-eslint/types": "4.22.0",
+ "@typescript-eslint/visitor-keys": "4.22.0"
}
},
"@typescript-eslint/types": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.19.0.tgz",
- "integrity": "sha512-A4iAlexVvd4IBsSTNxdvdepW0D4uR/fwxDrKUa+iEY9UWvGREu2ZyB8ylTENM1SH8F7bVC9ac9+si3LWNxcBuA=="
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/types/-/types-4.22.0.tgz",
+ "integrity": "sha512-sW/BiXmmyMqDPO2kpOhSy2Py5w6KvRRsKZnV0c4+0nr4GIcedJwXAq+RHNK4lLVEZAJYFltnnk1tJSlbeS9lYA=="
},
"@typescript-eslint/typescript-estree": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.19.0.tgz",
- "integrity": "sha512-3xqArJ/A62smaQYRv2ZFyTA+XxGGWmlDYrsfZG68zJeNbeqRScnhf81rUVa6QG4UgzHnXw5VnMT5cg75dQGDkA==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/typescript-estree/-/typescript-estree-4.22.0.tgz",
+ "integrity": "sha512-TkIFeu5JEeSs5ze/4NID+PIcVjgoU3cUQUIZnH3Sb1cEn1lBo7StSV5bwPuJQuoxKXlzAObjYTilOEKRuhR5yg==",
"requires": {
- "@typescript-eslint/types": "4.19.0",
- "@typescript-eslint/visitor-keys": "4.19.0",
+ "@typescript-eslint/types": "4.22.0",
+ "@typescript-eslint/visitor-keys": "4.22.0",
"debug": "^4.1.1",
"globby": "^11.0.1",
"is-glob": "^4.0.1",
@@ -1248,11 +1240,11 @@
}
},
"@typescript-eslint/visitor-keys": {
- "version": "4.19.0",
- "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.19.0.tgz",
- "integrity": "sha512-aGPS6kz//j7XLSlgpzU2SeTqHPsmRYxFztj2vPuMMFJXZudpRSehE3WCV+BaxwZFvfAqMoSd86TEuM0PQ59E/A==",
+ "version": "4.22.0",
+ "resolved": "https://registry.npmjs.org/@typescript-eslint/visitor-keys/-/visitor-keys-4.22.0.tgz",
+ "integrity": "sha512-nnMu4F+s4o0sll6cBSsTeVsT4cwxB7zECK3dFxzEjPBii9xLpq4yqqsy/FU5zMfan6G60DKZSCXAa3sHJZrcYw==",
"requires": {
- "@typescript-eslint/types": "4.19.0",
+ "@typescript-eslint/types": "4.22.0",
"eslint-visitor-keys": "^2.0.0"
}
},
@@ -1543,16 +1535,6 @@
"resolved": "https://registry.npmjs.org/array-unique/-/array-unique-0.3.2.tgz",
"integrity": "sha1-qJS3XUvE9s1nnvMkSp/Y9Gri1Cg="
},
- "array.prototype.flat": {
- "version": "1.2.4",
- "resolved": "https://registry.npmjs.org/array.prototype.flat/-/array.prototype.flat-1.2.4.tgz",
- "integrity": "sha512-4470Xi3GAPAjZqFcljX2xzckv1qeKPizoNkiS0+O4IoPR2ZNpcjE0pkhdihlDouK+x6QOast26B4Q/O9DJnwSg==",
- "requires": {
- "call-bind": "^1.0.0",
- "define-properties": "^1.1.3",
- "es-abstract": "^1.18.0-next.1"
- }
- },
"array.prototype.flatmap": {
"version": "1.2.4",
"resolved": "https://registry.npmjs.org/array.prototype.flatmap/-/array.prototype.flatmap-1.2.4.tgz",
@@ -1861,11 +1843,6 @@
"node-int64": "^0.4.0"
}
},
- "buf-compare": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/buf-compare/-/buf-compare-1.0.1.tgz",
- "integrity": "sha1-/vKNqLgROgoNtEMLC2Rntpcws0o="
- },
"buffer-from": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/buffer-from/-/buffer-from-1.1.1.tgz",
@@ -2054,14 +2031,9 @@
"integrity": "sha1-2Klr13/Wjfd5OnMDajug1UBdR3s="
},
"confusing-browser-globals": {
- "version": "1.0.9",
- "resolved": "https://registry.npmjs.org/confusing-browser-globals/-/confusing-browser-globals-1.0.9.tgz",
- "integrity": "sha512-KbS1Y0jMtyPgIxjO7ZzMAuUpAKMt1SzCL9fsrKsX6b0zJPTaT0SiSPmewwVZg9UAO83HVIlEhZF84LIjZ0lmAw=="
- },
- "contains-path": {
- "version": "0.1.0",
- "resolved": "https://registry.npmjs.org/contains-path/-/contains-path-0.1.0.tgz",
- "integrity": "sha1-/ozxhP9mcLa67wGp1IYaXL7EEgo="
+ "version": "1.0.10",
+ "resolved": "https://registry.npmjs.org/confusing-browser-globals/-/confusing-browser-globals-1.0.10.tgz",
+ "integrity": "sha512-gNld/3lySHwuhaVluJUKLePYirM3QNCKzVxqAdhJII9/WXKVX5PURzMVJspS1jTslSqjeuG4KMVTSouit5YPHA=="
},
"convert-source-map": {
"version": "1.7.0",
@@ -2076,15 +2048,6 @@
"resolved": "https://registry.npmjs.org/copy-descriptor/-/copy-descriptor-0.1.1.tgz",
"integrity": "sha1-Z29us8OZl8LuGsOpJP1hJHSPV40="
},
- "core-assert": {
- "version": "0.2.1",
- "resolved": "https://registry.npmjs.org/core-assert/-/core-assert-0.2.1.tgz",
- "integrity": "sha1-+F4s+b/tKPdzzIs/pcW2m9wC/j8=",
- "requires": {
- "buf-compare": "^1.0.0",
- "is-error": "^2.2.0"
- }
- },
"core-js-pure": {
"version": "3.9.1",
"resolved": "https://registry.npmjs.org/core-js-pure/-/core-js-pure-3.9.1.tgz",
@@ -2105,27 +2068,6 @@
"parse-json": "^5.0.0",
"path-type": "^4.0.0",
"yaml": "^1.10.0"
- },
- "dependencies": {
- "parse-json": {
- "version": "5.2.0",
- "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz",
- "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==",
- "requires": {
- "@babel/code-frame": "^7.0.0",
- "error-ex": "^1.3.1",
- "json-parse-even-better-errors": "^2.3.0",
- "lines-and-columns": "^1.1.6"
- }
- }
- }
- },
- "create-eslint-index": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/create-eslint-index/-/create-eslint-index-1.0.0.tgz",
- "integrity": "sha1-2VQ3LYbVeS/NZ+nyt5GxqxYkEbs=",
- "requires": {
- "lodash.get": "^4.3.0"
}
},
"cross-spawn": {
@@ -2209,14 +2151,6 @@
"resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.3.tgz",
"integrity": "sha1-s2nW+128E+7PUk+RsHD+7cNXzzQ="
},
- "deep-strict-equal": {
- "version": "0.2.0",
- "resolved": "https://registry.npmjs.org/deep-strict-equal/-/deep-strict-equal-0.2.0.tgz",
- "integrity": "sha1-SgeBR6irV/ag1PVUckPNIvROtOQ=",
- "requires": {
- "core-assert": "^0.2.0"
- }
- },
"deepmerge": {
"version": "4.2.2",
"resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.2.2.tgz",
@@ -2291,12 +2225,11 @@
}
},
"doctrine": {
- "version": "1.5.0",
- "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-1.5.0.tgz",
- "integrity": "sha1-N53Ocw9hZvds76TmcHoVmwLFpvo=",
+ "version": "2.1.0",
+ "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz",
+ "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==",
"requires": {
- "esutils": "^2.0.2",
- "isarray": "^1.0.0"
+ "esutils": "^2.0.2"
}
},
"dom-accessibility-api": {
@@ -2351,14 +2284,6 @@
"once": "^1.4.0"
}
},
- "enhance-visitors": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/enhance-visitors/-/enhance-visitors-1.0.0.tgz",
- "integrity": "sha1-qpRdBdpGVnKh69OP7i7T2oUY6Vo=",
- "requires": {
- "lodash": "^4.13.1"
- }
- },
"enhanced-resolve": {
"version": "5.7.0",
"resolved": "https://registry.npmjs.org/enhanced-resolve/-/enhanced-resolve-5.7.0.tgz",
@@ -2623,134 +2548,23 @@
}
}
},
- "eslint-ast-utils": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/eslint-ast-utils/-/eslint-ast-utils-1.1.0.tgz",
- "integrity": "sha512-otzzTim2/1+lVrlH19EfQQJEhVJSu0zOb9ygb3iapN6UlyaDtyRq4b5U1FuW0v1lRa9Fp/GJyHkSwm6NqABgCA==",
- "requires": {
- "lodash.get": "^4.4.2",
- "lodash.zip": "^4.2.0"
- }
- },
"eslint-config-prettier": {
- "version": "6.15.0",
- "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-6.15.0.tgz",
- "integrity": "sha512-a1+kOYLR8wMGustcgAjdydMsQ2A/2ipRPwRKUmfYaSxc9ZPcrku080Ctl6zrZzZNs/U82MjSv+qKREkoq3bJaw==",
- "requires": {
- "get-stdin": "^6.0.0"
- }
+ "version": "8.3.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-prettier/-/eslint-config-prettier-8.3.0.tgz",
+ "integrity": "sha512-BgZuLUSeKzvlL/VUjx/Yb787VQ26RU3gGjA3iiFvdsp/2bMfVIWUVP7tjxtjS0e+HP409cPlPvNkQloz8C91ew=="
},
"eslint-config-xo": {
- "version": "0.29.1",
- "resolved": "https://registry.npmjs.org/eslint-config-xo/-/eslint-config-xo-0.29.1.tgz",
- "integrity": "sha512-RDjeKh8CV0/EH4utW/6uOkwJJOOU+rX3uE5eUBOamcLNe4lNjyo8kSt3B6DzAm1L/1tWGikI7LFNVY9gG7PDQw==",
+ "version": "0.36.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-xo/-/eslint-config-xo-0.36.0.tgz",
+ "integrity": "sha512-RCaqCyI38awe3qgiO0Z8CqHs9yw7dMKdV6ZRTFSR7lm0//370tbDEZaQBXnztgpwe5m6D+VvFWc3vLMP/W6EAg==",
"requires": {
- "confusing-browser-globals": "1.0.9"
+ "confusing-browser-globals": "1.0.10"
}
},
"eslint-config-xo-react": {
- "version": "0.23.0",
- "resolved": "https://registry.npmjs.org/eslint-config-xo-react/-/eslint-config-xo-react-0.23.0.tgz",
- "integrity": "sha512-yBNoMF6COjJLRijlWksC1Jws6CGWHMgTfR/PAReCdZUo5cg/ZsyNeZx/fntyU4SbARwW2RvuezMeKle+jI5yoA=="
- },
- "eslint-import-resolver-node": {
- "version": "0.3.4",
- "resolved": "https://registry.npmjs.org/eslint-import-resolver-node/-/eslint-import-resolver-node-0.3.4.tgz",
- "integrity": "sha512-ogtf+5AB/O+nM6DIeBUNr2fuT7ot9Qg/1harBfBtaP13ekEWFQEEMP94BCB7zaNW3gyY+8SHYF00rnqYwXKWOA==",
- "requires": {
- "debug": "^2.6.9",
- "resolve": "^1.13.1"
- },
- "dependencies": {
- "debug": {
- "version": "2.6.9",
- "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
- "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
- "requires": {
- "ms": "2.0.0"
- }
- },
- "ms": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
- "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
- }
- }
- },
- "eslint-module-utils": {
- "version": "2.6.0",
- "resolved": "https://registry.npmjs.org/eslint-module-utils/-/eslint-module-utils-2.6.0.tgz",
- "integrity": "sha512-6j9xxegbqe8/kZY8cYpcp0xhbK0EgJlg3g9mib3/miLaExuuwc3n5UEfSnU6hWMbT0FAYVvDbL9RrRgpUeQIvA==",
- "requires": {
- "debug": "^2.6.9",
- "pkg-dir": "^2.0.0"
- },
- "dependencies": {
- "debug": {
- "version": "2.6.9",
- "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
- "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
- "requires": {
- "ms": "2.0.0"
- }
- },
- "find-up": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz",
- "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
- "requires": {
- "locate-path": "^2.0.0"
- }
- },
- "locate-path": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz",
- "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=",
- "requires": {
- "p-locate": "^2.0.0",
- "path-exists": "^3.0.0"
- }
- },
- "ms": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
- "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
- },
- "p-limit": {
- "version": "1.3.0",
- "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz",
- "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==",
- "requires": {
- "p-try": "^1.0.0"
- }
- },
- "p-locate": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz",
- "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
- "requires": {
- "p-limit": "^1.1.0"
- }
- },
- "p-try": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz",
- "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M="
- },
- "path-exists": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
- "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU="
- },
- "pkg-dir": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/pkg-dir/-/pkg-dir-2.0.0.tgz",
- "integrity": "sha1-9tXREJ4Z1j7fQo4L1X4Sd3YVM0s=",
- "requires": {
- "find-up": "^2.1.0"
- }
- }
- }
+ "version": "0.25.0",
+ "resolved": "https://registry.npmjs.org/eslint-config-xo-react/-/eslint-config-xo-react-0.25.0.tgz",
+ "integrity": "sha512-YpABFxnoATAYtxsZQChZEbOkWqzCtcQDRdiUqHhLgG7hzbAEzPDmsRUWnTP8oTVLVFWrbgdf913b8kQJaR1cBA=="
},
"eslint-plugin-10x": {
"version": "1.5.0",
@@ -2760,76 +2574,15 @@
"jsx-ast-utils": "^2.4.1"
}
},
- "eslint-plugin-ava": {
- "version": "10.5.0",
- "resolved": "https://registry.npmjs.org/eslint-plugin-ava/-/eslint-plugin-ava-10.5.0.tgz",
- "integrity": "sha512-2I0Ze8ZtwbSlLdnzms4bsa6PxxOxGMIJ9d4yy7aRy3yc5zEO2wHJLic8l3Lrct73hb5ML+PLt5VRqvdV87xWdQ==",
- "requires": {
- "deep-strict-equal": "^0.2.0",
- "enhance-visitors": "^1.0.0",
- "espree": "^7.1.0",
- "espurify": "^2.0.1",
- "import-modules": "^2.0.0",
- "micro-spelling-correcter": "^1.1.1",
- "pkg-dir": "^4.2.0",
- "resolve-from": "^5.0.0"
- }
- },
- "eslint-plugin-fp": {
- "version": "2.3.0",
- "resolved": "https://registry.npmjs.org/eslint-plugin-fp/-/eslint-plugin-fp-2.3.0.tgz",
- "integrity": "sha1-N20qEIcQ6YGYC9w4deO5kg2gSJw=",
- "requires": {
- "create-eslint-index": "^1.0.0",
- "eslint-ast-utils": "^1.0.0",
- "lodash": "^4.13.1",
- "req-all": "^0.1.0"
- }
- },
- "eslint-plugin-import": {
- "version": "2.22.1",
- "resolved": "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.22.1.tgz",
- "integrity": "sha512-8K7JjINHOpH64ozkAhpT3sd+FswIZTfMZTjdx052pnWrgRCVfp8op9tbjpAk3DdUeI/Ba4C8OjdC0r90erHEOw==",
- "requires": {
- "array-includes": "^3.1.1",
- "array.prototype.flat": "^1.2.3",
- "contains-path": "^0.1.0",
- "debug": "^2.6.9",
- "doctrine": "1.5.0",
- "eslint-import-resolver-node": "^0.3.4",
- "eslint-module-utils": "^2.6.0",
- "has": "^1.0.3",
- "minimatch": "^3.0.4",
- "object.values": "^1.1.1",
- "read-pkg-up": "^2.0.0",
- "resolve": "^1.17.0",
- "tsconfig-paths": "^3.9.0"
- },
- "dependencies": {
- "debug": {
- "version": "2.6.9",
- "resolved": "https://registry.npmjs.org/debug/-/debug-2.6.9.tgz",
- "integrity": "sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==",
- "requires": {
- "ms": "2.0.0"
- }
- },
- "ms": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/ms/-/ms-2.0.0.tgz",
- "integrity": "sha1-VgiurfwAvmwpAd9fmGF4jeDVl8g="
- }
- }
- },
"eslint-plugin-promise": {
- "version": "4.3.1",
- "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-4.3.1.tgz",
- "integrity": "sha512-bY2sGqyptzFBDLh/GMbAxfdJC+b0f23ME63FOE4+Jao0oZ3E1LEwFtWJX/1pGMJLiTtrSSern2CRM/g+dfc0eQ=="
+ "version": "5.1.0",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-promise/-/eslint-plugin-promise-5.1.0.tgz",
+ "integrity": "sha512-NGmI6BH5L12pl7ScQHbg7tvtk4wPxxj8yPHH47NvSmMtFneC077PSeY3huFj06ZWZvtbfxSPt3RuOQD5XcR4ng=="
},
"eslint-plugin-react": {
- "version": "7.23.1",
- "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.23.1.tgz",
- "integrity": "sha512-MvFGhZjI8Z4HusajmSw0ougGrq3Gs4vT/0WgwksZgf5RrLrRa2oYAw56okU4tZJl8+j7IYNuTM+2RnFEuTSdRQ==",
+ "version": "7.23.2",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-react/-/eslint-plugin-react-7.23.2.tgz",
+ "integrity": "sha512-AfjgFQB+nYszudkxRkTFu0UR1zEQig0ArVMPloKhxwlwkzaw/fBiH0QWcBBhZONlXqQC51+nfqFrkn4EzHcGBw==",
"requires": {
"array-includes": "^3.1.3",
"array.prototype.flatmap": "^1.2.4",
@@ -2845,14 +2598,6 @@
"string.prototype.matchall": "^4.0.4"
},
"dependencies": {
- "doctrine": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/doctrine/-/doctrine-2.1.0.tgz",
- "integrity": "sha512-35mSku4ZXK0vfCuHEDAwt55dg2jNajHZ1odvF+8SSr82EsZY4QmXfuWso8oEd8zRhVObSN18aM0CjSdoBX7zIw==",
- "requires": {
- "esutils": "^2.0.2"
- }
- },
"resolve": {
"version": "2.0.0-next.3",
"resolved": "https://registry.npmjs.org/resolve/-/resolve-2.0.0-next.3.tgz",
@@ -2870,14 +2615,14 @@
"integrity": "sha512-623WEiZJqxR7VdxFCKLI6d6LLpwJkGPYKODnkH3D7WpOG5KM8yWueBd8TLsNAetEJNF5iJmolaAKO3F8yzyVBQ=="
},
"eslint-plugin-react-native-normalized": {
- "version": "1.1.0",
- "resolved": "https://registry.npmjs.org/eslint-plugin-react-native-normalized/-/eslint-plugin-react-native-normalized-1.1.0.tgz",
- "integrity": "sha512-weEhGC5YssE/eFiZFLMX3mgYBT9OuTQG9CBRSURXFGcw+X2e3+FC6Rh9cpXUNLGPHvShUOpetf8kAXzqjS6dMg=="
+ "version": "1.1.1",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-react-native-normalized/-/eslint-plugin-react-native-normalized-1.1.1.tgz",
+ "integrity": "sha512-EB2hsftXGEEcka06WgQKLIWLmTUC5yx/mmeAznEpPVC+xV7yrhjML7O35tt/8mG5H9SEvwy+s4DX+bj+qjlC8Q=="
},
"eslint-plugin-ts-exports": {
- "version": "1.2.4",
- "resolved": "https://registry.npmjs.org/eslint-plugin-ts-exports/-/eslint-plugin-ts-exports-1.2.4.tgz",
- "integrity": "sha512-FecITVG1p0jepcFqVJZ2ISQNIZkwJLNlOUW/2C4KdjFGbu0go3xtsLcpmT9CwpihMY6n6FvXran0K1ZrSW1znQ==",
+ "version": "1.2.5",
+ "resolved": "https://registry.npmjs.org/eslint-plugin-ts-exports/-/eslint-plugin-ts-exports-1.2.5.tgz",
+ "integrity": "sha512-FlsOOE48hvWCv7tMeNBHeMl0QYG4p7nmGPxV00IIsobTzo9hpMdUzeH/+tuQ5Um1v9AIsLdoVQVqbO/wRUV6qw==",
"requires": {
"@typescript-eslint/experimental-utils": "^4.12.0",
"ts-prune": "https://firebasestorage.googleapis.com/v0/b/start-react-native.appspot.com/o/ts-prune-v0.0.3-wcandillon.tgz?alt=media&token=f5c337f6-c8bb-41dd-a958-cb9c52e2f6d1",
@@ -2935,11 +2680,6 @@
"resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz",
"integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A=="
},
- "espurify": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/espurify/-/espurify-2.1.0.tgz",
- "integrity": "sha512-QdTQGF6HgAij/6SklimO3KSEFUgUGvliDTGqvc+nRlybV/rrKizvyxcoSTcppuxYILZsWIBShoEp93ssIUCRsw=="
- },
"esquery": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/esquery/-/esquery-1.4.0.tgz",
@@ -3332,11 +3072,6 @@
"resolved": "https://registry.npmjs.org/get-package-type/-/get-package-type-0.1.0.tgz",
"integrity": "sha512-pjzuKtY64GYfWizNAJ0fr9VqttZkNiK2iS430LtIHzjBEr6bX8Am2zm4sW4Ro5wjWW5cAlRL1qAMTcXbjNAO2Q=="
},
- "get-stdin": {
- "version": "6.0.0",
- "resolved": "https://registry.npmjs.org/get-stdin/-/get-stdin-6.0.0.tgz",
- "integrity": "sha512-jp4tHawyV7+fkkSKyvjuLZswblUtz+SQKzSWnBbii16BuZksJlU1wuBYXY75r+duh/llF1ur6oNwi+2ZzjKZ7g=="
- },
"get-stream": {
"version": "4.1.0",
"resolved": "https://registry.npmjs.org/get-stream/-/get-stream-4.1.0.tgz",
@@ -3568,11 +3303,6 @@
"resolve-cwd": "^3.0.0"
}
},
- "import-modules": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/import-modules/-/import-modules-2.1.0.tgz",
- "integrity": "sha512-8HEWcnkbGpovH9yInoisxaSoIg9Brbul+Ju3Kqe2UsYDUBJD/iQjSgEj0zPcTDPKfPp2fs5xlv1i+JSye/m1/A=="
- },
"imurmurhash": {
"version": "0.1.4",
"resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz",
@@ -3719,11 +3449,6 @@
"integrity": "sha512-ZOoqiXfEwtGknTiuDEy8pN2CfE3TxMHprvNer1mXiqwkOT77Rw3YVrUQ52EqAOU3QAWDQ+bQdx7HJzrv7LS2Hw==",
"optional": true
},
- "is-error": {
- "version": "2.2.2",
- "resolved": "https://registry.npmjs.org/is-error/-/is-error-2.2.2.tgz",
- "integrity": "sha512-IOQqts/aHWbiisY5DuPJQ0gcbvaLFCa7fBa9xoLfxBZvQ+ZI/Zh9xoI7Gk+G64N0FdK4AbibytHht2tWgpJWLg=="
- },
"is-extendable": {
"version": "0.1.1",
"resolved": "https://registry.npmjs.org/is-extendable/-/is-extendable-0.1.1.tgz",
@@ -5232,17 +4957,6 @@
"resolved": "https://registry.npmjs.org/lines-and-columns/-/lines-and-columns-1.1.6.tgz",
"integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA="
},
- "load-json-file": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/load-json-file/-/load-json-file-2.0.0.tgz",
- "integrity": "sha1-eUfkIUmvgNaWy/eXvKq8/h/inKg=",
- "requires": {
- "graceful-fs": "^4.1.2",
- "parse-json": "^2.2.0",
- "pify": "^2.0.0",
- "strip-bom": "^3.0.0"
- }
- },
"loader-runner": {
"version": "4.2.0",
"resolved": "https://registry.npmjs.org/loader-runner/-/loader-runner-4.2.0.tgz",
@@ -5261,16 +4975,6 @@
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg=="
},
- "lodash.get": {
- "version": "4.4.2",
- "resolved": "https://registry.npmjs.org/lodash.get/-/lodash.get-4.4.2.tgz",
- "integrity": "sha1-LRd/ZS+jHpObRDjVNBSZ36OCXpk="
- },
- "lodash.zip": {
- "version": "4.2.0",
- "resolved": "https://registry.npmjs.org/lodash.zip/-/lodash.zip-4.2.0.tgz",
- "integrity": "sha1-7GZi5IlkCO1KtsVCo5kLcswIACA="
- },
"loose-envify": {
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz",
@@ -5336,11 +5040,6 @@
"resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz",
"integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg=="
},
- "micro-spelling-correcter": {
- "version": "1.1.1",
- "resolved": "https://registry.npmjs.org/micro-spelling-correcter/-/micro-spelling-correcter-1.1.1.tgz",
- "integrity": "sha512-lkJ3Rj/mtjlRcHk6YyCbvZhyWTOzdBvTHsxMmZSk5jxN1YyVSQ+JETAom55mdzfcyDrY/49Z7UCW760BK30crg=="
- },
"micromatch": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.2.tgz",
@@ -5577,9 +5276,9 @@
}
},
"object-inspect": {
- "version": "1.9.0",
- "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.9.0.tgz",
- "integrity": "sha512-i3Bp9iTqwhaLZBxGkRfo5ZbE07BQRT7MGu8+nNgwW9ItGp1TzCTw2DLEoWwjClxBjOFI/hWljTAmYGCEwmtnOw=="
+ "version": "1.10.2",
+ "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.10.2.tgz",
+ "integrity": "sha512-gz58rdPpadwztRrPjZE9DZLOABUpTGdcANUgOwBFO1C+HZZhePoP83M65WGDmbpwFYJSWqavbl4SgDn4k8RYTA=="
},
"object-keys": {
"version": "1.1.1",
@@ -5715,11 +5414,14 @@
}
},
"parse-json": {
- "version": "2.2.0",
- "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-2.2.0.tgz",
- "integrity": "sha1-9ID0BDTvgHQfhGkJn43qGPVaTck=",
+ "version": "5.2.0",
+ "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-5.2.0.tgz",
+ "integrity": "sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==",
"requires": {
- "error-ex": "^1.2.0"
+ "@babel/code-frame": "^7.0.0",
+ "error-ex": "^1.3.1",
+ "json-parse-even-better-errors": "^2.3.0",
+ "lines-and-columns": "^1.1.6"
}
},
"parse5": {
@@ -5767,11 +5469,6 @@
"resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.2.2.tgz",
"integrity": "sha512-q0M/9eZHzmr0AulXyPwNfZjtwZ/RBZlbN3K3CErVrk50T2ASYI7Bye0EvekFY3IP1Nt2DHu0re+V2ZHIpMkuWg=="
},
- "pify": {
- "version": "2.3.0",
- "resolved": "https://registry.npmjs.org/pify/-/pify-2.3.0.tgz",
- "integrity": "sha1-7RQaasBDqEnqWISY59yosVMw6Qw="
- },
"pirates": {
"version": "4.0.1",
"resolved": "https://registry.npmjs.org/pirates/-/pirates-4.0.1.tgz",
@@ -5913,80 +5610,6 @@
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
"integrity": "sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ=="
},
- "read-pkg": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-2.0.0.tgz",
- "integrity": "sha1-jvHAYjxqbbDcZxPEv6xGMysjaPg=",
- "requires": {
- "load-json-file": "^2.0.0",
- "normalize-package-data": "^2.3.2",
- "path-type": "^2.0.0"
- },
- "dependencies": {
- "path-type": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/path-type/-/path-type-2.0.0.tgz",
- "integrity": "sha1-8BLMuEFbcJb8LaoQVMPXI4lZTHM=",
- "requires": {
- "pify": "^2.0.0"
- }
- }
- }
- },
- "read-pkg-up": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/read-pkg-up/-/read-pkg-up-2.0.0.tgz",
- "integrity": "sha1-a3KoBImE4MQeeVEP1en6mbO1Sb4=",
- "requires": {
- "find-up": "^2.0.0",
- "read-pkg": "^2.0.0"
- },
- "dependencies": {
- "find-up": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/find-up/-/find-up-2.1.0.tgz",
- "integrity": "sha1-RdG35QbHF93UgndaK3eSCjwMV6c=",
- "requires": {
- "locate-path": "^2.0.0"
- }
- },
- "locate-path": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-2.0.0.tgz",
- "integrity": "sha1-K1aLJl7slExtnA3pw9u7ygNUzY4=",
- "requires": {
- "p-locate": "^2.0.0",
- "path-exists": "^3.0.0"
- }
- },
- "p-limit": {
- "version": "1.3.0",
- "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-1.3.0.tgz",
- "integrity": "sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==",
- "requires": {
- "p-try": "^1.0.0"
- }
- },
- "p-locate": {
- "version": "2.0.0",
- "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-2.0.0.tgz",
- "integrity": "sha1-IKAQOyIqcMj9OcwuWAaA893l7EM=",
- "requires": {
- "p-limit": "^1.1.0"
- }
- },
- "p-try": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/p-try/-/p-try-1.0.0.tgz",
- "integrity": "sha1-y8ec26+P1CKOE/Yh8rGiN8GyB7M="
- },
- "path-exists": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-3.0.0.tgz",
- "integrity": "sha1-zg6+ql94yxiSXqfYENe1mwEP1RU="
- }
- }
- },
"regenerator-runtime": {
"version": "0.13.7",
"resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.7.tgz",
@@ -6030,11 +5653,6 @@
"resolved": "https://registry.npmjs.org/repeat-string/-/repeat-string-1.6.1.tgz",
"integrity": "sha1-jcrkcOHIirwtYA//Sndihtp15jc="
},
- "req-all": {
- "version": "0.1.0",
- "resolved": "https://registry.npmjs.org/req-all/-/req-all-0.1.0.tgz",
- "integrity": "sha1-EwBR4qzligLqy/ydRIV3pzapJzo="
- },
"request": {
"version": "2.88.2",
"resolved": "https://registry.npmjs.org/request/-/request-2.88.2.tgz",
@@ -6817,11 +6435,6 @@
"ansi-regex": "^5.0.0"
}
},
- "strip-bom": {
- "version": "3.0.0",
- "resolved": "https://registry.npmjs.org/strip-bom/-/strip-bom-3.0.0.tgz",
- "integrity": "sha1-IzTBjpx1n3vdVv3vfprj1YjmjtM="
- },
"strip-eof": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/strip-eof/-/strip-eof-1.0.0.tgz",
@@ -7128,27 +6741,6 @@
"ts-morph": "^7.3.0"
}
},
- "tsconfig-paths": {
- "version": "3.9.0",
- "resolved": "https://registry.npmjs.org/tsconfig-paths/-/tsconfig-paths-3.9.0.tgz",
- "integrity": "sha512-dRcuzokWhajtZWkQsDVKbWyY+jgcLC5sqJhg2PSgf4ZkH2aHPvaOY8YWGhmjb68b5qqTfasSsDO9k7RUiEmZAw==",
- "requires": {
- "@types/json5": "^0.0.29",
- "json5": "^1.0.1",
- "minimist": "^1.2.0",
- "strip-bom": "^3.0.0"
- },
- "dependencies": {
- "json5": {
- "version": "1.0.1",
- "resolved": "https://registry.npmjs.org/json5/-/json5-1.0.1.tgz",
- "integrity": "sha512-aKS4WQjPenRxiQsC93MNfjx+nbF4PAdYzmd/1JIj8HYzqfbu86beTuNgXDzPknWk0n0uARlyewZo4s++ES36Ow==",
- "requires": {
- "minimist": "^1.2.0"
- }
- }
- }
- },
"tslib": {
"version": "1.14.1",
"resolved": "https://registry.npmjs.org/tslib/-/tslib-1.14.1.tgz",
@@ -7207,14 +6799,14 @@
"integrity": "sha512-qOcYwxaByStAWrBf4x0fibwZvMRG+r4cQoTjbPtUlrWjBHbmCAww1i448U0GJ+3cNNEtebDteo/cHOR3xJ4wEw=="
},
"unbox-primitive": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.0.tgz",
- "integrity": "sha512-P/51NX+JXyxK/aigg1/ZgyccdAxm5K1+n8+tvqSntjOivPt19gvm1VC49RWYetsiub8WViUchdxl/KWHHB0kzA==",
+ "version": "1.0.1",
+ "resolved": "https://registry.npmjs.org/unbox-primitive/-/unbox-primitive-1.0.1.tgz",
+ "integrity": "sha512-tZU/3NqK3dA5gpE1KtyiJUrEB0lxnGkMFHptJ7q6ewdZ8s12QrODwNbhIJStmJkd1QDXa1NRA8aF2A1zk/Ypyw==",
"requires": {
"function-bind": "^1.1.1",
- "has-bigints": "^1.0.0",
- "has-symbols": "^1.0.0",
- "which-boxed-primitive": "^1.0.1"
+ "has-bigints": "^1.0.1",
+ "has-symbols": "^1.0.2",
+ "which-boxed-primitive": "^1.0.2"
}
},
"unc-path-regex": {
diff --git a/packages/player/package.json b/packages/player/package.json
index 71fd18a650..b2fcf9c2f1 100644
--- a/packages/player/package.json
+++ b/packages/player/package.json
@@ -5,7 +5,7 @@
"main": "dist/index.js",
"sideEffects": false,
"scripts": {
- "test": "jest",
+ "test": "eslint src --ext ts,tsx && jest",
"build": "tsc -d",
"watch": "tsc -w",
"prerelease": "cp ../../README.md ."
diff --git a/packages/player/src/PlayPause.ts b/packages/player/src/PlayPause.ts
index 61e21b7979..03575a6459 100644
--- a/packages/player/src/PlayPause.ts
+++ b/packages/player/src/PlayPause.ts
@@ -56,9 +56,11 @@ export const usePlayback = (): {
if (!video) {
return null;
}
+
if (playing) {
return;
}
+
if (frame === 0) {
return;
}
@@ -76,6 +78,7 @@ export const usePlayback = (): {
if (!video) {
return null;
}
+
if (playing) {
return;
}
@@ -93,6 +96,7 @@ export const usePlayback = (): {
if (!config) {
return;
}
+
if (!playing) {
return;
}
@@ -110,6 +114,7 @@ export const usePlayback = (): {
if (calculatedFrame !== frameRef.current) {
setFrame(calculatedFrame);
}
+
if (!hasBeenStopped) {
reqAnimFrameCall = requestAnimationFrame(callback);
}
diff --git a/packages/player/src/Player.tsx b/packages/player/src/Player.tsx
index 784ab6c44f..d7b89ca1ae 100644
--- a/packages/player/src/Player.tsx
+++ b/packages/player/src/Player.tsx
@@ -90,14 +90,14 @@ export const PlayerFn = <T,>(
},
],
currentComposition: 'player-comp',
- registerComposition: () => void 0,
- registerSequence: () => void 0,
+ registerComposition: () => undefined,
+ registerSequence: () => undefined,
sequences: [],
- setCurrentComposition: () => void 0,
- unregisterComposition: () => void 0,
- unregisterSequence: () => void 0,
- registerAsset: () => void 0,
- unregisterAsset: () => void 0,
+ setCurrentComposition: () => undefined,
+ unregisterComposition: () => undefined,
+ unregisterSequence: () => undefined,
+ registerAsset: () => undefined,
+ unregisterAsset: () => undefined,
assets: [],
};
}, [component, props, durationInFrames, fps, height, width]);
diff --git a/packages/player/src/PlayerSeekBar.tsx b/packages/player/src/PlayerSeekBar.tsx
index 3f096d66b9..5bd5579e8d 100644
--- a/packages/player/src/PlayerSeekBar.tsx
+++ b/packages/player/src/PlayerSeekBar.tsx
@@ -65,6 +65,7 @@ export const PlayerSeekBar: React.FC<{
if (!size) {
throw new Error('Player has no size');
}
+
const _frame = getFrameFromX(
e.clientX - size.left,
durationInFrames,
@@ -85,9 +86,11 @@ export const PlayerSeekBar: React.FC<{
if (!size) {
throw new Error('Player has no size');
}
+
if (!dragging.dragging) {
return;
}
+
const _frame = getFrameFromX(
e.clientX - (size?.left ?? 0),
durationInFrames,
@@ -105,6 +108,7 @@ export const PlayerSeekBar: React.FC<{
if (!dragging.dragging) {
return;
}
+
if (dragging.wasPlaying) {
play();
} else {
@@ -116,6 +120,7 @@ export const PlayerSeekBar: React.FC<{
if (!dragging.dragging) {
return;
}
+
window.addEventListener('pointermove', onPointerMove);
window.addEventListener('pointerup', onPointerUp);
return () => {
diff --git a/packages/player/src/RootComponent.tsx b/packages/player/src/RootComponent.tsx
index 970c8cebe9..3ed659ad7e 100644
--- a/packages/player/src/RootComponent.tsx
+++ b/packages/player/src/RootComponent.tsx
@@ -63,6 +63,7 @@ const RootComponent: React.ForwardRefRenderFunction<
if (!config) {
return {};
}
+
return {
position: 'relative',
width: config.width,
diff --git a/packages/player/src/event-emitter.ts b/packages/player/src/event-emitter.ts
index 8c6c207384..3bd219f875 100644
--- a/packages/player/src/event-emitter.ts
+++ b/packages/player/src/event-emitter.ts
@@ -4,9 +4,9 @@ type SeekPayload = {
interface StateEventMap {
seeked: CustomEvent<SeekPayload>;
- pause: CustomEvent;
- play: CustomEvent;
- ended: CustomEvent;
+ pause: CustomEvent<undefined>;
+ play: CustomEvent<undefined>;
+ ended: CustomEvent<undefined>;
}
export interface PlayerEventTarget extends EventTarget {
@@ -37,12 +37,15 @@ export class PlayerEmitter extends PlayerEventEmitter {
})
);
}
+
dispatchPause() {
this.dispatchEvent(new CustomEvent('pause'));
}
+
dispatchPlay() {
this.dispatchEvent(new CustomEvent('play'));
}
+
dispatchEnded() {
this.dispatchEvent(new CustomEvent('ended'));
}
diff --git a/packages/player/src/test/index.test.ts b/packages/player/src/test/index.test.ts
index 70afd053b9..5610f33359 100644
--- a/packages/player/src/test/index.test.ts
+++ b/packages/player/src/test/index.test.ts
@@ -1,7 +1,7 @@
-import {usePlaybackTime} from '../index';
+import {usePlayback} from '../index';
test('It should throw an error if not being used inside a RemotionRoot', () => {
expect(() => {
- usePlaybackTime();
+ usePlayback();
}).toThrow();
});
diff --git a/packages/player/src/use-element-size.ts b/packages/player/src/use-element-size.ts
index b5ff83f31d..84648dda37 100644
--- a/packages/player/src/use-element-size.ts
+++ b/packages/player/src/use-element-size.ts
@@ -28,10 +28,12 @@ export const useElementSize = (
if (!ref.current) {
return;
}
+
const rect = ref.current.getClientRects();
if (!rect[0]) {
return;
}
+
setSize({
width: rect[0].width as number,
height: rect[0].height as number,
@@ -46,6 +48,7 @@ export const useElementSize = (
if (ref.current) {
observer.observe(ref.current);
}
+
return (): void => {
if (current) {
observer.unobserve(current);
diff --git a/packages/player/src/use-hover-state.ts b/packages/player/src/use-hover-state.ts
index aac302ed36..7bbbc3ee70 100644
--- a/packages/player/src/use-hover-state.ts
+++ b/packages/player/src/use-hover-state.ts
@@ -8,9 +8,11 @@ export const useHoverState = (ref: React.RefObject<HTMLDivElement>) => {
if (!current) {
return;
}
+
const onHover = () => {
stetHovered(true);
};
+
const onLeave = () => {
stetHovered(false);
};