From 7cb6db93f4013e29c3181a6de552e4e1343bb684 Mon Sep 17 00:00:00 2001 From: hockeymikey Date: Sat, 29 Apr 2023 10:31:11 -0500 Subject: [PATCH] Add in rss parsing library and option to use it instead of the API --- docs/widgets.md | 1 + package.json | 3 +- src/components/Widgets/RssFeed.vue | 70 +++++++++++++++++++++--------- yarn.lock | 23 +++++++++- 4 files changed, 74 insertions(+), 23 deletions(-) diff --git a/docs/widgets.md b/docs/widgets.md index 550dd6fd..b36a4a8f 100644 --- a/docs/widgets.md +++ b/docs/widgets.md @@ -219,6 +219,7 @@ Display news and updates from any RSS-enabled service. **`limit`** | `number` | _Optional_ | The number of posts to return. If you haven't specified an API key, this will be limited to 10 **`orderBy`** | `string` | _Optional_ | How results should be sorted. Can be either `pubDate`, `author` or `title`. Defaults to `pubDate` **`orderDirection`** | `string` | _Optional_ | Order direction of feed items to return. Can be either `asc` or `desc`. Defaults to `desc` +**`parseLocally`** | `boolean` | _Optional_ | If true parse the rss feed locally instead of using the rss2json API. #### Example diff --git a/package.json b/package.json index 47a7b119..e6413a0d 100644 --- a/package.json +++ b/package.json @@ -43,7 +43,8 @@ "vue-select": "^3.20.2", "vue-swatches": "^2.1.1", "vue-toasted": "^1.1.28", - "vuex": "^3.6.2" + "vuex": "^3.6.2", + "rss-parser": "3.13.0" }, "devDependencies": { "@architect/sandbox": "^4.5.2", diff --git a/src/components/Widgets/RssFeed.vue b/src/components/Widgets/RssFeed.vue index 94f8398a..6faf0899 100644 --- a/src/components/Widgets/RssFeed.vue +++ b/src/components/Widgets/RssFeed.vue @@ -31,6 +31,7 @@