Skip to content

Commit

Permalink
feat: deal exclusively with a tree, not html
Browse files Browse the repository at this point in the history
  • Loading branch information
sergioramos committed Nov 14, 2020
1 parent 7d86777 commit 6f5da71
Show file tree
Hide file tree
Showing 35 changed files with 1,491 additions and 1,013 deletions.
8 changes: 4 additions & 4 deletions .github/workflows/on-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
uses: actions/[email protected]
with:
path: .yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-node-modules-${{ hashFiles('yarn.lock') }}
- name: Install dependencies
run: yarn install --immutable
env:
Expand Down Expand Up @@ -56,7 +56,7 @@ jobs:
uses: actions/[email protected]
with:
path: .yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-node-modules-${{ hashFiles('yarn.lock') }}
- name: Install dependencies
run: yarn install --immutable --immutable-cache
- name: ESLint
Expand All @@ -79,7 +79,7 @@ jobs:
uses: actions/[email protected]
with:
path: .yarn
key: ${{ runner.os }}-yarn-${{ hashFiles('yarn.lock') }}
key: ${{ runner.os }}-node-modules-${{ hashFiles('yarn.lock') }}
- name: Install dependencies
run: yarn install --immutable --immutable-cache
- name: Test
Expand All @@ -88,7 +88,7 @@ jobs:
with:
token: ${{ secrets.GITHUB_TOKEN }}
result_path: coverage/lcov.info
min_coverage: 90
min_coverage: 85
type: lcov

###############################################################################
Expand Down
16 changes: 10 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,16 @@ It supports some [Prism](https://prismjs.com/) plugins:
remark()
.use(require('remark-prism'), {
plugins: [
'prismjs/plugins/autolinker/prism-autolinker',
'prismjs/plugins/diff-highlight/prism-diff-highlight',
'prismjs/plugins/inline-color/prism-inline-color',
'prismjs/plugins/line-numbers/prism-line-numbers',
'prismjs/plugins/treeview/prism-treeview',
'prismjs/plugins/show-invisibles/prism-show-invisibles',
'autolinker',
'command-line',
'data-uri-highlight',
'diff-highlight',
'inline-color',
'keep-markup',
'line-numbers',
'line-highlight',
'show-invisibles',
'treeview',
],
})
.use(require('remark-html'))
Expand Down
229 changes: 0 additions & 229 deletions index.js

This file was deleted.

23 changes: 13 additions & 10 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "Syntax highlighter for markdown code blocks - with support for plugins",
"license": "BSD-3-Clause",
"repository": "sergioramos/remark-prism",
"main": "index.js",
"main": "src/index.js",
"keywords": [
"prismjs",
"markdown",
Expand All @@ -25,30 +25,33 @@
"classnames": "^2.2.6",
"css-selector-parser": "^1.4.1",
"escape-html": "^1.0.3",
"hast-util-to-html": "^7.1.1",
"hastscript": "^6.0.0",
"jsdom": "^16.4.0",
"parse-numeric-range": "^1.2.0",
"parse5": "^6.0.1",
"parse5-htmlparser2-tree-adapter": "^6.0.1",
"prismjs": "^1.22.0",
"unist-builder": "^2.0.3",
"unist-util-map": "^2.0.1"
},
"devDependencies": {
"@commitlint/cli": "^11.0.0",
"@commitlint/config-conventional": "^11.0.0",
"ava": "^3.13.0",
"c8": "^7.3.5",
"eslint": "^7.12.0",
"eslint-config-prettier": "^6.14.0",
"eslint": "^7.13.0",
"eslint-config-prettier": "^6.15.0",
"eslint-config-xo-space": "^0.25.0",
"husky": "^4.3.0",
"lint-staged": "^10.4.2",
"lint-staged": "^10.5.1",
"mz": "^2.7.0",
"npm-run-all": "^4.1.5",
"prettier": "^2.1.2",
"puppeteer": "^5.4.0",
"remark": "^13.0.0",
"remark-html": "^13.0.1"
"puppeteer": "^5.4.1",
"rehype-format": "^3.1.0",
"rehype-stringify": "^8.0.0",
"remark-parse": "^9.0.0",
"serve": "^11.3.2",
"to-vfile": "^6.1.0",
"unified": "^9.2.0"
},
"husky": {
"hooks": {
Expand Down
Loading

0 comments on commit 6f5da71

Please sign in to comment.