Skip to content

Commit

Permalink
Merge pull request #263 from ndaidong/v6.0.1
Browse files Browse the repository at this point in the history
v6.0.1
  • Loading branch information
ndaidong authored May 28, 2022
2 parents dd96b6c + 4442450 commit 93ff3e5
Show file tree
Hide file tree
Showing 11 changed files with 236 additions and 151 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:

strategy:
matrix:
node_version: [14.x, 15.x, 16.x, 17.x]
node_version: [14.x, 15.x, 16.x, 17.x, 18.x]

steps:
- uses: actions/checkout@v2
Expand Down
70 changes: 70 additions & 0 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
# For most projects, this workflow file will not need changing; you simply need
# to commit it to your repository.
#
# You may wish to alter this file to override the set of languages analyzed,
# or to provide custom queries or build logic.
#
# ******** NOTE ********
# We have attempted to detect the languages in your repository. Please check
# the `language` matrix defined below to confirm you have the correct set of
# supported CodeQL languages.
#
name: "CodeQL"

on:
push:
branches: [ main ]
pull_request:
# The branches below must be a subset of the branches above
branches: [ main ]
schedule:
- cron: '33 18 * * 3'

jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
language: [ 'javascript' ]
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ]
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support

steps:
- name: Checkout repository
uses: actions/checkout@v3

# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: ${{ matrix.language }}
# If you wish to specify custom queries, you can do so here or in a config file.
# By default, queries listed here will override any specified in a config file.
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
# If this step fails, then you should remove it and run the build manually (see below)
- name: Autobuild
uses: github/codeql-action/autobuild@v2

# ℹ️ Command-line programs to run using the OS shell.
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun

# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
# and modify them (or add more) to build your code if your project
# uses a compiled language

#- run: |
# make bootstrap
# make release

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Extract main article, main image and meta data from URL.
[![NPM](https://badge.fury.io/js/article-parser.svg)](https://badge.fury.io/js/article-parser)
![CI test](https://github.com/ndaidong/article-parser/workflows/ci-test/badge.svg)
[![Coverage Status](https://coveralls.io/repos/github/ndaidong/article-parser/badge.svg)](https://coveralls.io/github/ndaidong/article-parser)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=ndaidong_article-parser&metric=alert_status)](https://sonarcloud.io/dashboard?id=ndaidong_article-parser)
![CodeQL](https://github.com/ndaidong/article-parser/workflows/CodeQL/badge.svg)
[![JavaScript Style Guide](https://img.shields.io/badge/code_style-standard-brightgreen.svg)](https://standardjs.com)


Expand Down
106 changes: 53 additions & 53 deletions dist/article-parser.browser.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/article-parser.browser.js.map

Large diffs are not rendered by default.

172 changes: 93 additions & 79 deletions dist/cjs/article-parser.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/cjs/article-parser.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/cjs/package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"name": "article-parser-cjs",
"version": "6.0.0",
"version": "6.0.1",
"main": "./article-parser.js"
}
2 changes: 1 addition & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ const config = {
transform: {},
// TODO https://github.com/makotoshimazu/jest-module-field-resolver/issues/2
moduleNameMapper: {
'urlpattern-polyfill': '<rootDir>/node_modules/urlpattern-polyfill/dist/index.js'
'urlpattern-polyfill': '<rootDir>/node_modules/urlpattern-polyfill/index.js'
}
}
export default config
16 changes: 8 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "6.0.0",
"version": "6.0.1",
"name": "article-parser",
"description": "To extract main article from given URL",
"homepage": "https://ndaidong.github.io/article-parser-demo/",
Expand Down Expand Up @@ -30,14 +30,14 @@
},
"dependencies": {
"@mozilla/readability": "^0.4.2",
"axios": "^0.26.1",
"axios": "^0.27.2",
"bellajs": "^11.0.2",
"debug": "^4.3.4",
"html-crush": "^5.0.12",
"linkedom": "^0.14.5",
"html-crush": "^5.0.18",
"linkedom": "^0.14.9",
"sanitize-html": "^2.7.0",
"string-comparison": "^1.1.0",
"urlpattern-polyfill": "^4.0.2"
"urlpattern-polyfill": "^5.0.3"
},
"standard": {
"ignore": [
Expand All @@ -47,10 +47,10 @@
"devDependencies": {
"@types/sanitize-html": "^2.6.2",
"cross-env": "^7.0.3",
"esbuild": "^0.14.34",
"jest": "^27.5.1",
"esbuild": "^0.14.41",
"jest": "^28.1.0",
"nock": "^13.2.4",
"standard": "^16.0.4"
"standard": "^17.0.0"
},
"keywords": [
"article",
Expand Down
3 changes: 2 additions & 1 deletion src/utils/findRulesByUrl.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
// utils --> findRulesByUrl

import { getQueryRules } from '../config.js'
import { URLPattern } from 'urlpattern-polyfill'

import { getQueryRules } from '../config.js'

/**
* @param urls {string[]}
* @returns {QueryRule|{}}
Expand Down

0 comments on commit 93ff3e5

Please sign in to comment.