Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disabling formatting of the block of code #438

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Lev135
Copy link
Contributor

@Lev135 Lev135 commented Dec 29, 2022

Here is one of the possible solutions to this issue. It's very straightforward: just collecting all edits and then filtering them and applying only those, that doesn't intersect with the block of code between {- stylish_disable -} and {- stylish_enable -}.

Filtering is applied by rows only, so, in this sample

data Foo = Foo Int {- stylish_disable -}
{- stylish_enable -}

data will not be reformated. In the first my iplementation columns also were taken into account, but this made the code much more havier and didn't make much sense for me: such constructions as in example above seems too artificial.

Anyway this issue was discussed several times here (#409 is the latest one). So it seems to be very helpful feature, not for me only. So it would be nice to discuss and resolve it one way or another

Copy link
Member

@jaspervdj jaspervdj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like the approach of doing this in Editor — I will look at the implementation in more detail once I’m back from holidays.

@Lev135
Copy link
Contributor Author

Lev135 commented May 31, 2023

@jaspervdj
Sorry to disturb you, but I'm wonder, whether any progress with merging PRs can be expected in the nearest future. The reason is that I'm working on my project and the lack of this feature and some bugs in stylish (mostly #425) cause many inconveniences. Of course, I can build this all in my fork and use it instead of the main repo, but it would be much clearer if it can be used directly. Please, let me note if I can somehow facilitate the process.
Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants