diff --git a/CHANGELOG.md b/CHANGELOG.md index 143efe692..f26e4773f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,13 @@ All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines. +## [13.2.0](https://github.com/documentationjs/documentation/compare/v13.1.1...v13.2.0) (2021-03-13) + + +### Features + +* Support import.meta ([d449e7c](https://github.com/documentationjs/documentation/commit/d449e7c3ca0abb7379ea4159b0ef0281059077eb)), closes [#1345](https://github.com/documentationjs/documentation/issues/1345) + ### [13.1.1](https://github.com/documentationjs/documentation/compare/v13.1.0...v13.1.1) (2021-01-19) ## [13.1.0](https://github.com/documentationjs/documentation/compare/v13.0.2...v13.1.0) (2020-10-24) diff --git a/__tests__/__snapshots__/test.js.snap b/__tests__/__snapshots__/test.js.snap index 7f7220ab1..3ced4f9b6 100644 --- a/__tests__/__snapshots__/test.js.snap +++ b/__tests__/__snapshots__/test.js.snap @@ -20854,6 +20854,27 @@ Object { } `; +exports[`outputs import.meta.input.js JSON 1`] = `Array []`; + +exports[`outputs import.meta.input.js markdown 1`] = ` +" + +### Table of Contents +" +`; + +exports[`outputs import.meta.input.js markdown AST 1`] = ` +Object { + "children": Array [ + Object { + "type": "html", + "value": "", + }, + ], + "type": "root", +} +`; + exports[`outputs infer-private.input.js JSON 1`] = ` Array [ Object { diff --git a/__tests__/fixture/import.meta.input.js b/__tests__/fixture/import.meta.input.js new file mode 100644 index 000000000..a2fd80604 --- /dev/null +++ b/__tests__/fixture/import.meta.input.js @@ -0,0 +1,4 @@ +import x from "y"; + + +console.log(import.meta.url); \ No newline at end of file diff --git a/docs/THEMING.md b/docs/THEMING.md index 052f6dc2a..cd9761c9f 100644 --- a/docs/THEMING.md +++ b/docs/THEMING.md @@ -33,6 +33,35 @@ for some ideas. - You can now make changes that will show up when you generate your docs using your theme. Example `package.json` `scripts` entry: `"documentation build index.js -f html -o docs --theme node_modules/docjs-theme"` +#### Changes to Default Theme Via documentation.yml +If a documentation.yml file is used to establish a table of contents for your documentation, small changes to the default style can be made via a + + + ### Sub Section header + Text that describes the section and sub-section here. +``` +Any changes to elements and classes that also exist in the standard theme will be overwridden by what is in the documentation.yml. This opens up the possiblitity of the same CSS being defined twice, which can be confusing and is not best practice. However, it is easy to change HTML style this way. Recommend only using classes defined this way that do not exist in the standard documentation.js theme. + ### Theming Markdown The default Markdown generator for documentation.js isn't customizable - instead diff --git a/package.json b/package.json index 380dfef2b..fd01469de 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "documentation", "description": "a documentation generator", - "version": "13.1.1", + "version": "13.2.0", "author": "Tom MacWright", "homepage": "https://documentation.js.org", "bin": { @@ -53,7 +53,7 @@ "mdast-util-inject": "^1.1.0", "micromatch": "^3.1.5", "mime": "^2.2.0", - "module-deps-sortable": "^5.0.1", + "module-deps-sortable": "^5.0.3", "parse-filepath": "^1.0.2", "pify": "^5.0.0", "read-pkg-up": "^4.0.0", diff --git a/yarn.lock b/yarn.lock index 55f9c0e62..c86cc8e8d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -291,6 +291,11 @@ resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.5.tgz#b4af32ddd473c0bfa643bd7ff0728b8e71b81ea0" integrity sha512-FVM6RZQ0mn2KCf1VUED7KepYeUWoVShczewOCfm3nzoBybaih51h+sYVVGthW9M6lPByEPTQf+xm27PBdlpwmQ== +"@babel/parser@^7.10.5", "@babel/parser@^7.12.7": + version "7.12.7" + resolved "https://registry.yarnpkg.com/@babel/parser/-/parser-7.12.7.tgz#fee7b39fe809d0e73e5b25eecaf5780ef3d73056" + integrity sha512-oWR02Ubp4xTLCAqPRiNIuMVgNO5Aif/xpXtabhzW2HWUD47XJsAB4Zd/Rg30+XeQA3juXigV7hlquOTmwqLiwg== + "@babel/plugin-proposal-async-generator-functions@^7.12.1": version "7.12.1" resolved "https://registry.yarnpkg.com/@babel/plugin-proposal-async-generator-functions/-/plugin-proposal-async-generator-functions-7.12.1.tgz#dc6c1170e27d8aca99ff65f4925bd06b1c90550e" @@ -1063,6 +1068,21 @@ globals "^11.1.0" lodash "^4.17.19" +"@babel/traverse@^7.10.5": + version "7.12.7" + resolved "https://registry.yarnpkg.com/@babel/traverse/-/traverse-7.12.7.tgz#572a722408681cef17d6b0bef69ef2e728ca69f1" + integrity sha512-nMWaqsQEeSvMNypswUDzjqQ+0rR6pqCtoQpsqGJC4/Khm9cISwPTSpai57F6/jDaOoEGz8yE/WxcO3PV6tKSmQ== + dependencies: + "@babel/code-frame" "^7.10.4" + "@babel/generator" "^7.12.5" + "@babel/helper-function-name" "^7.10.4" + "@babel/helper-split-export-declaration" "^7.11.0" + "@babel/parser" "^7.12.7" + "@babel/types" "^7.12.7" + debug "^4.1.0" + globals "^11.1.0" + lodash "^4.17.19" + "@babel/types@^7.0.0", "@babel/types@^7.10.4", "@babel/types@^7.10.5", "@babel/types@^7.11.0", "@babel/types@^7.12.1", "@babel/types@^7.12.5", "@babel/types@^7.3.0", "@babel/types@^7.3.3", "@babel/types@^7.4.4", "@babel/types@^7.7.0": version "7.12.6" resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.12.6.tgz#ae0e55ef1cce1fbc881cd26f8234eb3e657edc96" @@ -1072,6 +1092,15 @@ lodash "^4.17.19" to-fast-properties "^2.0.0" +"@babel/types@^7.12.7": + version "7.12.7" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.12.7.tgz#6039ff1e242640a29452c9ae572162ec9a8f5d13" + integrity sha512-MNyI92qZq6jrQkXvtIiykvl4WtoRrVV9MPn+ZfsoEENjiWcBQ3ZSHrkxnJWgWtLX3XXqX5hrSQ+X69wkmesXuQ== + dependencies: + "@babel/helper-validator-identifier" "^7.10.4" + lodash "^4.17.19" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -4789,6 +4818,14 @@ kleur@^3.0.3: resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== +konan@^2.1.1: + version "2.1.1" + resolved "https://registry.yarnpkg.com/konan/-/konan-2.1.1.tgz#eea88f05c56249b78903b952b953393900346dd1" + integrity sha512-7ZhYV84UzJ0PR/RJnnsMZcAbn+kLasJhVNWsu8ZyVEJYRpGA5XESQ9d/7zOa08U0Ou4cmB++hMNY/3OSV9KIbg== + dependencies: + "@babel/parser" "^7.10.5" + "@babel/traverse" "^7.10.5" + lazystream@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/lazystream/-/lazystream-1.0.0.tgz#f6995fe0f820392f61396be89462407bb77168e4" @@ -5343,10 +5380,10 @@ modify-values@^1.0.0: resolved "https://registry.yarnpkg.com/modify-values/-/modify-values-1.0.1.tgz#b3939fa605546474e3e3e3c63d64bd43b4ee6022" integrity sha512-xV2bxeN6F7oYjZWTe/YPAy6MN2M+sL4u/Rlm2AHCIVGfo2p1yGmBHQ6vHehl4bRTZBdHu3TSkWdYgkwpYzAGSw== -module-deps-sortable@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/module-deps-sortable/-/module-deps-sortable-5.0.1.tgz#b7eec1cb1e556e97db152a78292f768752797615" - integrity sha512-QCQPk/u41XIBX5Hy2PCDyXS5kg2tZZSQGedEhfvZa2bO4FhxUov+4/2WSXZ5dNtvuyMnqBcfCau6XJZp9DqJoA== +module-deps-sortable@^5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/module-deps-sortable/-/module-deps-sortable-5.0.3.tgz#e640e7450e0869f4ae8e03437665ca2a8a28f843" + integrity sha512-eiyIZj/A0dj1o4ywXWqicazUL3l0HP3TydUR6xF0X3xh3LGBMLqW8a9aFe6MuNH4mxNMk53QKBHM6LOPR8kSgw== dependencies: JSONStream "^1.0.3" browser-resolve "^1.7.0" @@ -5356,6 +5393,7 @@ module-deps-sortable@^5.0.1: detective "^5.2.0" duplexer2 "^0.1.2" inherits "^2.0.1" + konan "^2.1.1" readable-stream "^2.0.2" resolve "^1.1.3" standard-version "^9.0.0"