Merge branch 'dev' of github.com:estruyf/vscode-front-matter into dev

This commit is contained in:
Elio Struyf
2023-03-02 21:23:02 +01:00
4 changed files with 7 additions and 4 deletions
+2
View File
@@ -19,6 +19,8 @@
### 🐞 Fixes
- [#518](https://github.com/estruyf/vscode-front-matter/issues/518): Fix an issue where the `YAML` parser adds line breaks to long strings
## [8.3.0] - 2022-02-14 - [Release notes](https://beta.frontmatter.codes/updates/v8.3.0)
### 🧪 Experimental features
+1 -1
View File
@@ -203,7 +203,7 @@ export class ArticleHelper {
noArrayIndent: !indentArray,
skipInvalid: true,
noCompatMode: true,
lineWidth: 500,
lineWidth: 50000,
indent: spaces || 2
} as DumpOptions as any);
}
@@ -12,7 +12,6 @@ export const CustomView: React.FunctionComponent<ICustomViewProps> = ({ metadata
const [customHtml, setCustomHtml] = useState<string | undefined>(undefined);
useEffect(() => {
console.log(window.fmExternal)
if (window.fmExternal && window.fmExternal.getPanelView) {
window.fmExternal.getPanelView(metadata).then((viewDetails: CustomPanelViewResult | undefined) => {
if (viewDetails && viewDetails.title && viewDetails.content) {
+4 -2
View File
@@ -1,4 +1,5 @@
import * as yaml from 'yaml';
import * as jsyaml from 'js-yaml';
import * as toml from '@iarna/toml';
import { Format, FrontMatterParser } from '.';
@@ -48,11 +49,12 @@ export const Engines = {
}
}
return docYaml.toString();
const jsonObj = docYaml.toJSON();
return jsyaml.dump(jsonObj, options);
}
}
return yaml.stringify(obj, options);
return jsyaml.dump(obj, options);
}
}
}