@adobe/jsonschema2md 8.1.0 → 8.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/lib/markdownBuilder.js +2 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,11 @@
|
|
|
1
|
+
## [8.1.1](https://github.com/adobe/jsonschema2md/compare/v8.1.0...v8.1.1) (2026-12-04)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **markdownBuilder:** keep trailing newlines of YAML block scalars ([202e5de](https://github.com/adobe/jsonschema2md/commit/202e5dec5acdf717fff9a7eb68d5a54080f4232d)), closes [#789](https://github.com/adobe/jsonschema2md/issues/789)
|
|
7
|
+
* **markdownBuilder:** remove trailing blank line from YAML examples ([e18db78](https://github.com/adobe/jsonschema2md/commit/e18db7841563abcd4063646b480173d28bb666ae)), closes [#247](https://github.com/adobe/jsonschema2md/issues/247)
|
|
8
|
+
|
|
1
9
|
# [8.1.0](https://github.com/adobe/jsonschema2md/compare/v8.0.11...v8.1.0) (2026-12-04)
|
|
2
10
|
|
|
3
11
|
|
package/lib/markdownBuilder.js
CHANGED
|
@@ -720,7 +720,8 @@ export default function build({
|
|
|
720
720
|
if (schema[keyword`examples`] && schema[keyword`examples`].length > 0 && exampleFormat === 'yaml') {
|
|
721
721
|
return [
|
|
722
722
|
heading(level + 1, text(i18n`${simpletitle(schema)} Examples`)),
|
|
723
|
-
|
|
723
|
+
// only drop the final newline: more would change `|+` block scalars
|
|
724
|
+
...schema[keyword`examples`].map((example) => paragraph(code('yaml', yaml.dump(example, undefined, 2).replace(/\n$/, '')))),
|
|
724
725
|
];
|
|
725
726
|
}
|
|
726
727
|
if (schema[keyword`examples`] && schema[keyword`examples`].length > 0 && exampleFormat === 'json') {
|