mirror of
https://github.com/facebook/docusaurus.git
synced 2025-06-08 05:42:34 +02:00
refactor: print trailing new line when outputting JSON (#6186)
* refactor(core): print trailing new line when writing translation * Print these as well
This commit is contained in:
parent
a17deb6aa2
commit
1460f867d0
3 changed files with 5 additions and 5 deletions
|
@ -66,7 +66,7 @@ function generateTemplateExample(template) {
|
|||
// rewrite the package.json file with the new edit
|
||||
writeFileSync(
|
||||
`./examples/${template}/package.json`,
|
||||
JSON.stringify(templatePackageJson, null, 2),
|
||||
`${JSON.stringify(templatePackageJson, null, 2)}\n`,
|
||||
);
|
||||
|
||||
// create sandbox.config.json file at the root of template
|
||||
|
@ -82,7 +82,7 @@ function generateTemplateExample(template) {
|
|||
};
|
||||
writeFileSync(
|
||||
`./examples/${template}/sandbox.config.json`,
|
||||
JSON.stringify(codeSanboxConfig, null, 2),
|
||||
`${JSON.stringify(codeSanboxConfig, null, 2)}\n`,
|
||||
);
|
||||
|
||||
const stackBlitzConfig = {
|
||||
|
@ -91,7 +91,7 @@ function generateTemplateExample(template) {
|
|||
};
|
||||
writeFileSync(
|
||||
`./examples/${template}/.stackblitzrc`,
|
||||
JSON.stringify(stackBlitzConfig, null, 2),
|
||||
`${JSON.stringify(stackBlitzConfig, null, 2)}\n`,
|
||||
);
|
||||
|
||||
console.log(`Generated example for template ${template}`);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue