Skip to content

Commit

Permalink
deps: update to latest remark-parse and unified
Browse files Browse the repository at this point in the history
These changes are backward compatible to users, just had to make a
small change in the compiler code.
  • Loading branch information
quantizor committed Apr 20, 2017
1 parent fb29ebe commit 5ac0b90
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 12 deletions.
4 changes: 2 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -591,11 +591,11 @@ export function compiler(markdown, {overrides = {}} = {}) {
}`);
}

const remarkAST = unified().use(parser).parse(markdown, {
const remarkAST = unified().data('settings', {
footnotes: true,
gfm: true,
position: false,
});
}).use(parser).parse(markdown);

const extracted = extractDefinitionsFromASTTree(remarkAST, astToJSX);

Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@
"dependencies": {
"lodash.get": "^4.4.2",
"prop-types": "^15.5.8",
"remark-parse": "^2.0.1",
"unified": "^5.0.0"
"remark-parse": "^3.0.0",
"unified": "^6.1.2"
},
"peerDependencies": {
"react": ">= 0.14.0"
Expand Down
29 changes: 21 additions & 8 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -2406,6 +2406,10 @@ is-number@^2.0.2, is-number@^2.1.0:
dependencies:
kind-of "^3.0.2"

is-plain-obj@^1.1.0:
version "1.1.0"
resolved "https://registry.yarnpkg.com/is-plain-obj/-/is-plain-obj-1.1.0.tgz#71a50c8429dfca773c92a390a4a03b39fcd51d3e"

is-posix-bracket@^0.1.0:
version "0.1.1"
resolved "https://registry.yarnpkg.com/is-posix-bracket/-/is-posix-bracket-0.1.1.tgz#3334dc79774368e92f016e6fbc0a88f5cd6e6bc4"
Expand Down Expand Up @@ -2442,6 +2446,10 @@ isarray@1.0.0, isarray@^1.0.0, isarray@~1.0.0:
version "1.0.0"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-1.0.0.tgz#bb935d48582cba168c06834957a54a3e07124f11"

isarray@^2.0.1:
version "2.0.1"
resolved "https://registry.yarnpkg.com/isarray/-/isarray-2.0.1.tgz#a37d94ed9cda2d59865c9f76fe596ee1f338741e"

isexe@^2.0.0:
version "2.0.0"
resolved "https://registry.yarnpkg.com/isexe/-/isexe-2.0.0.tgz#e8fbf374dc556ff8947a10dcb0572d633f2cfa10"
Expand Down Expand Up @@ -3671,9 +3679,9 @@ regjsparser@^0.1.4:
dependencies:
jsesc "~0.5.0"

remark-parse@^2.0.1:
version "2.3.0"
resolved "https://registry.yarnpkg.com/remark-parse/-/remark-parse-2.3.0.tgz#ced58bfbef9999374f9ff33fbc2e63fe2b0c5c37"
remark-parse@^3.0.0:
version "3.0.0"
resolved "https://registry.yarnpkg.com/remark-parse/-/remark-parse-3.0.0.tgz#f078c8c9976efb0f2afd011c79f30708354593b1"
dependencies:
collapse-white-space "^1.0.2"
has "^1.0.1"
Expand Down Expand Up @@ -4329,17 +4337,18 @@ unherit@^1.0.4:
inherits "^2.0.1"
xtend "^4.0.1"

unified@^5.0.0:
version "5.1.0"
resolved "https://registry.yarnpkg.com/unified/-/unified-5.1.0.tgz#61268da9b91ce925be1f3d198c0278b0e9716094"
unified@^6.1.2:
version "6.1.2"
resolved "https://registry.yarnpkg.com/unified/-/unified-6.1.2.tgz#b3904c3254ffbea7ff6d806c5d5b6248838cecb6"
dependencies:
bail "^1.0.0"
extend "^3.0.0"
has "^1.0.1"
is-buffer "^1.1.4"
once "^1.3.3"
is-plain-obj "^1.1.0"
isarray "^2.0.1"
trough "^1.0.0"
vfile "^2.0.0"
x-is-function "^1.0.4"
x-is-string "^0.1.0"

unist-util-remove-position@^1.0.0:
Expand Down Expand Up @@ -4548,6 +4557,10 @@ wrappy@1:
version "1.0.2"
resolved "https://registry.yarnpkg.com/wrappy/-/wrappy-1.0.2.tgz#b5243d8f3ec1aa35f1364605bc0d1036e30ab69f"

x-is-function@^1.0.4:
version "1.0.4"
resolved "https://registry.yarnpkg.com/x-is-function/-/x-is-function-1.0.4.tgz#5d294dc3d268cbdd062580e0c5df77a391d1fa1e"

x-is-string@^0.1.0:
version "0.1.0"
resolved "https://registry.yarnpkg.com/x-is-string/-/x-is-string-0.1.0.tgz#474b50865af3a49a9c4657f05acd145458f77d82"
Expand Down

0 comments on commit 5ac0b90

Please sign in to comment.