prettier-plugin-svelte
Advanced tools
Comparing version 2.1.2 to 2.1.3
# prettier-plugin-svelte changelog | ||
## 2.1.3 | ||
* Don't print an empty line at the end of code embedded inside Markdown ([#202](https://github.com/sveltejs/prettier-plugin-svelte/issues/202)) | ||
## 2.1.2 | ||
@@ -4,0 +8,0 @@ |
{ | ||
"name": "prettier-plugin-svelte", | ||
"version": "2.1.2", | ||
"version": "2.1.3", | ||
"description": "Svelte plugin for prettier", | ||
@@ -5,0 +5,0 @@ "main": "plugin.js", |
@@ -1175,2 +1175,10 @@ 'use strict'; | ||
svelteOptionsDoc = undefined; | ||
// If this is invoked as an embed of markdown, remove the last hardline. | ||
// The markdown parser tries this, too, but fails because it does not | ||
// recurse into concats. Doing this will prevent an empty line | ||
// at the end of the embedded code block. | ||
if (options.parentParser === 'markdown') { | ||
const lastDoc = docs[docs.length - 1]; | ||
trimRight([lastDoc], isLine); | ||
} | ||
return groupConcat([join(hardline, docs)]); | ||
@@ -1177,0 +1185,0 @@ } |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
206348
1683