-
Notifications
You must be signed in to change notification settings - Fork 200
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
Support for code regions #285
Comments
My feeling has long been that For C#, the argument was that much of that code was generated WinForms code, so it made sense to be able to hide it. But I think partial classes (which if I recall came later) were a cleaner solution because it let you move that stuff to a separate physical file. That makes it much easier to integrate with code generators and otherwise manage things more cleanly. For Dart, in many cases you can use mixins to break up a giant class into smaller more manageable pieces. You can even, if you want, put those all into the same file, which then also plays nice with library privacy. I think that would be a better approach than applying a band-aid like |
I think this is solved with a plugin for the IDE |
which plugin? |
This features would be useful |
while i agree with @munificent i think that in the other hand we have a spread of too much files and in some cases is useless to create another class in another file just to introduce one or two methods that can be more easily implemented on the file you already have. |
Here's another vote for code regions as a useful feature. While I agree with @munificent regarding classes that grow too large, I don't know that code regions actually encourage that growth. Sometimes bad developers are bad no matter how hard you wish they were better :) Also, in some cases you may not have total control over the organization of your class. For example, you may be implementing a particularly large interface from an external package. In these cases, code regions can at least help organize the clutter from that (sometimes poorly designed) interface. |
This Feature will be very useful in managing parts for class, or parts of code written by different team members. |
I would also love this, although I think it really only needs to be part of the vscode extension, not specifically the sdk?
|
Yeah, it's definitely possible for an IDE to support regions just by recognizing comments that contain some special marker text. In that case, no language support is needed. |
Can we have code regions facility for dart just like #region in c# for structural code blocks purpose. And thus can be used in flutter also
The text was updated successfully, but these errors were encountered: