@slidev/parser 0.48.9 → 0.49.0-beta.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/dist/fs.d.mts CHANGED
@@ -8,6 +8,6 @@ declare function injectPreparserExtensionLoader(fn: PreparserExtensionLoader): v
8
8
  */
9
9
  type LoadedSlidevData = Omit<SlidevData, 'config' | 'themeMeta'>;
10
10
  declare function load(userRoot: string, filepath: string, content?: string, mode?: string): Promise<LoadedSlidevData>;
11
- declare function save(markdown: SlidevMarkdown): Promise<void>;
11
+ declare function save(markdown: SlidevMarkdown): Promise<string>;
12
12
 
13
13
  export { type LoadedSlidevData, injectPreparserExtensionLoader, load, save };
package/dist/fs.mjs CHANGED
@@ -91,7 +91,9 @@ async function load(userRoot, filepath, content, mode) {
91
91
  };
92
92
  }
93
93
  async function save(markdown) {
94
- await fs.writeFile(markdown.filepath, stringify(markdown), "utf-8");
94
+ const fileContent = stringify(markdown);
95
+ await fs.writeFile(markdown.filepath, fileContent, "utf-8");
96
+ return fileContent;
95
97
  }
96
98
  export {
97
99
  detectFeatures,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@slidev/parser",
3
- "version": "0.48.9",
3
+ "version": "0.49.0-beta.1",
4
4
  "description": "Markdown parser for Slidev",
5
5
  "author": "antfu <anthonyfu117@hotmail.com>",
6
6
  "license": "MIT",
@@ -40,7 +40,7 @@
40
40
  },
41
41
  "dependencies": {
42
42
  "js-yaml": "^4.1.0",
43
- "@slidev/types": "0.48.9"
43
+ "@slidev/types": "0.49.0-beta.1"
44
44
  },
45
45
  "scripts": {
46
46
  "build": "rimraf dist && tsup src/index.ts src/core.ts src/fs.ts",