We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Originally posted by TwentyFourMinutes November 2, 2022 Currently when you have a linq syntax query it will produce something like the following:
var result = await ( from post in dbContext.Posts where post.Id == 1 select post ) .AsNoTracking() .FirstAsync();
which seems fine at first, however, these queries can get quite large fairly quickly. We currently manually format it with empty lines e.g.
var result = await ( from post in dbContext.Posts join blog in dbContext.Blogs on post.BlogId equals blog.Id let count = dbContext.Posts.Count(p => p.Name == post.Name) where post.Id == 1 select new { Post = post, Blog = blog, SamePostNameCount = count } ) .AsNoTracking() .FirstAsync();
Anyhow, csharpier would strip out empty lines which can get very unreadable on even larger queries.
Proposal: Allow single blank lines between two statements, but truncate more than that down to 1.
Do you have had any thoughts on this yet? Or on this rather small proposal?
The text was updated successfully, but these errors were encountered:
Allow empty lines in query syntax
c6f37ed
closes #754
c32bbfd
Successfully merging a pull request may close this issue.
Discussed in https://github.com/belav/csharpier/discussions/750
Originally posted by TwentyFourMinutes November 2, 2022
Currently when you have a linq syntax query it will produce something like the following:
which seems fine at first, however, these queries can get quite large fairly quickly. We currently manually format it with empty lines e.g.
Anyhow, csharpier would strip out empty lines which can get very unreadable on even larger queries.
Proposal:
Allow single blank lines between two statements, but truncate more than that down to 1.
Do you have had any thoughts on this yet? Or on this rather small proposal?
The text was updated successfully, but these errors were encountered: