SergeyKasyanov / vscode-october-extension

VSCode extension for work with OctoberCMS
MIT License
20 stars 2 forks source link

The extension doesn't respect new lines or single/double quotes when formatting a Twig file #15

Closed davidkvasnovsky closed 3 months ago

davidkvasnovsky commented 11 months ago

Description

There appears to be an issue with the extension when formatting Twig files. Specifically, the extension does not respect new lines or single/double quotes.

Steps to Reproduce

  1. Open a Twig file.
  2. Apply formatting using the extension.

Expected Behavior

The formatted file should maintain new lines and the integrity of single/double quotes.

Actual Behavior

After formatting, the new lines and single/double quotes are not preserved correctly.

Proposed Solution

It would be beneficial to have an option to control the formatting behavior regarding new lines and quotes. This could provide flexibility according to different users' needs.

Screenshots

Before formatting:

image

After formatting:

image
SergeyKasyanov commented 10 months ago

Hello. Just published new version (0.25). Single/double quotes now should preserve correctly.

SergeyKasyanov commented 3 months ago

Hello. Check out 0.29.0. I made some improvements in formatting, also OctoberCode now support .prettierrc config files, so you can change some formatting behavior by this.