Skip to content

Commit

Permalink
chore(deps): bump all unified dependencies (#683)
Browse files Browse the repository at this point in the history
#### What this PR does / why we need it:

As per title.
  • Loading branch information
fuxingloh committed Nov 3, 2023
1 parent aec41ad commit fd59dc4
Show file tree
Hide file tree
Showing 6 changed files with 283 additions and 379 deletions.
24 changes: 12 additions & 12 deletions packages/contented-pipeline-md/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,33 +42,33 @@
"@contentedjs/contented-pipeline": "workspace:*",
"@jsdevtools/rehype-toc": "^3.0.2",
"@sindresorhus/slugify": "^2.2.1",
"hast-util-to-string": "^2.0.0",
"hast-util-to-string": "^3.0.0",
"hastscript": "^8.0.0",
"js-yaml": "^4.1.0",
"lodash": "^4.17.21",
"mdast-util-directive": "^3.0.0",
"mdast-util-to-string": "^4.0.0",
"minimatch": "^5.1.6",
"rehype-autolink-headings": "^7.0.0",
"rehype-external-links": "^2.1.0",
"rehype-parse": "^8.0.5",
"rehype-external-links": "^3.0.0",
"rehype-parse": "^9.0.0",
"rehype-slug": "^6.0.0",
"rehype-stringify": "^9.0.4",
"remark-directive": "^2.0.1",
"rehype-stringify": "^10.0.0",
"remark-directive": "^3.0.0",
"remark-embed-images": "^4.0.0",
"remark-frontmatter": "^5.0.0",
"remark-gfm": "^3.0.1",
"remark-parse": "^10.0.2",
"remark-rehype": "^10.1.0",
"remark-gfm": "^4.0.0",
"remark-parse": "^11.0.0",
"remark-rehype": "^11.0.0",
"shiki": "^0.14.5",
"to-vfile": "^7.2.4",
"unified": "^10.1.2",
"to-vfile": "^8.0.0",
"unified": "^11.0.4",
"unist-util-map": "^4.0.0",
"unist-util-visit": "^5.0.0",
"vfile": "^5.3.7"
"vfile": "^6.0.1"
},
"devDependencies": {
"@types/hast": "^2.3.7",
"@types/hast": "^3.0.2",
"@types/js-yaml": "^4.0.8",
"@types/lodash": "^4.14.200",
"@types/mdast": "^4.0.2",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { h } from 'hastscript';
import { Node } from 'mdast';
import { Node, Parent } from 'mdast';
import { Directives } from 'mdast-util-directive';
import { Plugin } from 'unified';
import { Transformer } from 'unified';
import { map, MapFunction } from 'unist-util-map';

const isDirectiveNode = (node: Node): node is Directives => {
Expand Down Expand Up @@ -47,6 +47,6 @@ const mapDirectiveNode: MapFunction<Node> = (node: Node) => {
return node;
};

export function remarkDirectiveRehype(): Plugin {
return (nodeTree) => map(nodeTree, mapDirectiveNode);
export function remarkDirectiveRehype(): Transformer<Parent> {
return (nodeTree: any) => map(nodeTree, mapDirectiveNode);
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ it('should process RemarkLink.md', async () => {
path: '/remark-link',
fileId: expect.stringMatching(/[0-f]{64}/),
modifiedDate: expect.any(Number),
html: '<nav class="toc"><ol class="toc-level toc-level-1"><li class="toc-item toc-item-h1"><a class="toc-link toc-link-h1" href="#remarklinkts">RemarkLink.ts</a><ol class="toc-level toc-level-2"><li class="toc-item toc-item-h2"><a class="toc-link toc-link-h2" href="#test-links">Test Links</a></li></ol></li></ol></nav><h1 id="remarklinkts"><a aria-hidden="true" tabindex="-1" href="#remarklinkts"><span class="icon icon-link"></span></a><code>RemarkLink.ts</code></h1>\n<p><code>RemarkLink.ts</code> will automatically link to other markdown files in your repository.</p>\n<h2 id="test-links"><a aria-hidden="true" tabindex="-1" href="#test-links"><span class="icon icon-link"></span></a>Test Links</h2>\n<ul>\n<li><a href="heading/remark-linked">20-Heading/100-RemarkLinked.md</a></li>\n<li><a href="remark-linked">01-RemarkLinked.md</a></li>\n<li><a href="remark-link">RemarkLink.md</a></li>\n<li><a href="https://contented.dev" target="_blank" rel="nofollow">Contented</a></li>\n<li><a href="heading/remark-linked">20-Heading/100-RemarkLinked.md</a></li>\n<li><a href="heading/section-title/deep-link">20-Heading/40-Section Title/200-DeepLink.md</a></li>\n<li><a href="remark-linked">01-RemarkLinked.md</a></li>\n</ul>',
html: '<nav class="toc"><ol class="toc-level toc-level-1"><li class="toc-item toc-item-h1"><a class="toc-link toc-link-h1" href="#remarklinkts">RemarkLink.ts</a><ol class="toc-level toc-level-2"><li class="toc-item toc-item-h2"><a class="toc-link toc-link-h2" href="#test-links">Test Links</a></li></ol></li></ol></nav><h1 id="remarklinkts"><a aria-hidden="true" tabindex="-1" href="#remarklinkts"><span class="icon icon-link"></span></a><code>RemarkLink.ts</code></h1>\n<p><code>RemarkLink.ts</code> will automatically link to other markdown files in your repository.</p>\n<h2 id="test-links"><a aria-hidden="true" tabindex="-1" href="#test-links"><span class="icon icon-link"></span></a>Test Links</h2>\n<ul>\n<li><a href="heading/remark-linked">20-Heading/100-RemarkLinked.md</a></li>\n<li><a href="remark-linked">01-RemarkLinked.md</a></li>\n<li><a href="remark-link">RemarkLink.md</a></li>\n<li><a href="https://contented.dev" rel="nofollow" target="_blank">Contented</a></li>\n<li><a href="heading/remark-linked">20-Heading/100-RemarkLinked.md</a></li>\n<li><a href="heading/section-title/deep-link">20-Heading/40-Section Title/200-DeepLink.md</a></li>\n<li><a href="remark-linked">01-RemarkLinked.md</a></li>\n</ul>',
},
]);
});
Expand Down
1 change: 0 additions & 1 deletion packages/contented-pipeline/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@
"@sindresorhus/slugify": "^2.2.1"
},
"devDependencies": {
"@types/unist": "^2.0.9",
"@workspace/jest-preset": "workspace:*",
"@workspace/tsconfig": "workspace:*"
}
Expand Down
2 changes: 1 addition & 1 deletion packages/jest-preset/jest-preset.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ module.exports = {
preset: 'ts-jest',
reporters: ['default', 'github-actions'],
moduleNameMapper: {
'(.+)\\.js': '$1',
'(\\..+)\\.js': '$1',
},
transform: {
'^.+\\.ts$': 'ts-jest',
Expand Down

0 comments on commit fd59dc4

Please sign in to comment.