chore(deps): upgrade and make specialized deps optional (#1259) [skip ci]

This commit is contained in:
Simon Lecoq
2022-10-16 20:19:36 -04:00
committed by GitHub
parent 09c17d20ff
commit 948ec35697
4 changed files with 1076 additions and 998 deletions

2039
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@@ -31,22 +31,20 @@
"dependencies": {
"@actions/core": "^1.10.0",
"@actions/github": "^5.1.1",
"@faker-js/faker": "^7.5.0",
"@googlemaps/google-maps-services-js": "^3.3.16",
"@octokit/graphql": "^5.0.1",
"@octokit/rest": "^19.0.4",
"@primer/css": "^20.4.6",
"@faker-js/faker": "^7.6.0",
"@octokit/graphql": "^5.0.3",
"@octokit/rest": "^19.0.5",
"@primer/css": "^20.4.7",
"@primer/octicons": "^17.7.0",
"axios": "^0.27.2",
"axios": "^1.1.3",
"clipboard": "^2.0.11",
"color": "^4.2.3",
"compression": "^1.7.4",
"csso": "^5.0.5",
"d3": "^7.6.1",
"d3-node": "^3.0.0",
"ejs": "^3.1.8",
"emoji-name-map": "^1.2.9",
"express": "^4.18.1",
"express": "^4.18.2",
"express-rate-limit": "^6.6.0",
"file-type": "^18.0.0",
"js-yaml": "^4.1.0",
@@ -58,7 +56,7 @@
"open-graph-scraper": "^4.11.1",
"png-js": "^1.0.0",
"prismjs": "^1.29.0",
"puppeteer": "^18.2.1",
"puppeteer": "^19.0.0",
"purgecss": "^5.0.0",
"rss-parser": "^3.12.0",
"sanitize-html": "^2.7.2",
@@ -68,12 +66,11 @@
"twemoji-parser": "^14.0.0",
"vue": "^2.7.1",
"vue-prism-component": "^1.2.0",
"xml-formatter": "^2.6.1",
"yargs-parser": "^21.1.1"
"xml-formatter": "^2.6.1"
},
"devDependencies": {
"eslint": "^8.25.0",
"jest": "^29.1.2",
"jest": "^29.2.0",
"libxmljs2": "^0.30.1"
},
"jest": {
@@ -82,9 +79,13 @@
"transform": {}
},
"optionalDependencies": {
"@googlemaps/google-maps-services-js": "^3.3.16",
"chess.js": "^1.0.0-alpha.0",
"color": "^4.2.3",
"gifencoder": "^2.0.1",
"libxmljs2": "^0.30.1",
"node-chartist": "^1.0.5"
"node-chartist": "^1.0.5",
"rss": "^1.2.2",
"yargs-parser": "^21.1.1"
}
}

View File

@@ -23,7 +23,6 @@ import prism_lang from "prismjs/components/index.js"
import _puppeteer from "puppeteer"
import purgecss from "purgecss"
import readline from "readline"
import rss from "rss-parser"
import htmlsanitize from "sanitize-html"
import sharp from "sharp"
import git from "simple-git"
@@ -35,7 +34,7 @@ import xmlformat from "xml-formatter"
prism_lang()
//Exports
export { axios, d3, D3node, emoji, fetch, fs, git, minimatch, opengraph, os, paths, processes, rss, sharp, url, util }
export { axios, d3, D3node, emoji, fetch, fs, git, minimatch, opengraph, os, paths, processes, sharp, url, util }
/**Returns module __dirname */
export function __module(module) {

View File

@@ -1,3 +1,6 @@
//Imports
import rss from "rss-parser"
//Setup
export default async function({login, q, imports, data, account}, {enabled = false, extras = false} = {}) {
//Plugin execution
@@ -12,7 +15,7 @@ export default async function({login, q, imports, data, account}, {enabled = fal
throw {error: {message: "RSS feed URL is not set"}}
//Load rss feed
const {title, description, link, items} = await (new imports.rss()).parseURL(source) //eslint-disable-line new-cap
const {title, description, link, items} = await (new rss()).parseURL(source) //eslint-disable-line new-cap
const feed = items.map(({title, link, isoDate: date}) => ({title, link, date: new Date(date)}))
//Limit feed