chore(deps): drop @types/cheerio

Not required for cheerio v1 (DefinitelyTyped/DefinitelyTyped#72495).
This commit is contained in:
Tiago de Paula 2025-10-26 18:43:51 -03:00
commit 776462e6a9
No known key found for this signature in database
GPG key ID: 55BD118E42C985CF
3 changed files with 2 additions and 11 deletions

View file

@ -95,7 +95,6 @@
"@textcomplete/core": "^0.1.13",
"@textcomplete/textarea": "^0.1.13",
"@types/chai": "^4.3.20",
"@types/cheerio": "^0.22.35",
"@types/content-disposition": "^0.5.9",
"@types/express": "^4.17.25",
"@types/is-utf8": "^0.2.3",

View file

@ -139,8 +139,7 @@ function parseHtml(preview, res, client: Client) {
});
}
// TODO: type $
function parseHtmlMedia($: any, preview, client: Client): Promise<FetchRequest> {
function parseHtmlMedia($: cheerio.CheerioAPI, preview, client: Client): Promise<FetchRequest> {
return new Promise((resolve, reject) => {
if (Config.values.disableMediaPreview) {
reject();
@ -167,7 +166,7 @@ function parseHtmlMedia($: any, preview, client: Client): Promise<FetchRequest>
return;
}
$(`meta[property="og:${type}:type"]`).each(function (this: cheerio.Element, i: number) {
$(`meta[property="og:${type}:type"]`).each(function (i: number) {
const mimeType = $(this).attr("content");
if (!mimeType) {

View file

@ -1790,13 +1790,6 @@
resolved "https://registry.yarnpkg.com/@types/chai/-/chai-4.3.20.tgz#cb291577ed342ca92600430841a00329ba05cecc"
integrity sha512-/pC9HAB5I/xMlc5FP77qjCnI16ChlJfW0tGa0IUcFn38VJrTV6DeZ60NU5KZBtaOZqjdpwTWohz5HU1RrhiYxQ==
"@types/cheerio@^0.22.35":
version "0.22.35"
resolved "https://registry.yarnpkg.com/@types/cheerio/-/cheerio-0.22.35.tgz#0d16dc1f24d426231c181b9c31847f673867595f"
integrity sha512-yD57BchKRvTV+JD53UZ6PD8KWY5g5rvvMLRnZR3EQBCZXiDT/HR+pKpMzFGlWNhFrXlo7VPZXtKvIEwZkAWOIA==
dependencies:
"@types/node" "*"
"@types/connect@*":
version "3.4.38"
resolved "https://registry.yarnpkg.com/@types/connect/-/connect-3.4.38.tgz#5ba7f3bc4fbbdeaff8dded952e5ff2cc53f8d858"