@markdoc/markdoc 0.1.8 → 0.1.9
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/README.md +8 -1
- package/dist/index.js +5 -2
- package/dist/index.js.map +2 -2
- package/dist/index.mjs +5 -2
- package/dist/index.mjs.map +2 -2
- package/dist/src/formatter.d.ts.map +1 -1
- package/package.json +2 -2
- package/src/formatter.test.ts +38 -0
- package/src/formatter.ts +6 -3
package/dist/index.mjs
CHANGED
|
@@ -7007,7 +7007,10 @@ function* formatFunction(f) {
|
|
|
7007
7007
|
function* trimStart(g) {
|
|
7008
7008
|
let n;
|
|
7009
7009
|
do {
|
|
7010
|
-
|
|
7010
|
+
const { value, done } = g.next();
|
|
7011
|
+
if (done)
|
|
7012
|
+
return;
|
|
7013
|
+
n = value.trimStart();
|
|
7011
7014
|
} while (!n.length);
|
|
7012
7015
|
yield n;
|
|
7013
7016
|
yield* g;
|
|
@@ -7096,7 +7099,7 @@ function* formatNode(n, o = {}) {
|
|
|
7096
7099
|
yield* formatAnnotations(n);
|
|
7097
7100
|
yield NL;
|
|
7098
7101
|
yield indent;
|
|
7099
|
-
yield
|
|
7102
|
+
yield n.attributes.content;
|
|
7100
7103
|
yield indent;
|
|
7101
7104
|
yield "```";
|
|
7102
7105
|
yield NL;
|