1) Show Class Separators. Draws horizontal line separators above class, enum and extension definitions in the Editor, similar to the native "Show Method Separator" setting, but applied to classes instead. This enhances code readability, making it easier to distinguish where one class ends and another begins.
2) Show Test and Test Group Separators. Draws horizontal line separators above test()
and group()
method calls in the Editor, for files that end in _test.dart
. That's similar to the
native "Show Method Separator" setting, but applied to tests instead. This enhances code
readability, making it easier to distinguish where one test or test group ends and another begins.
This plugin is needed because tests are function calls, not function definitions, which is why
they don't have the native method separators applied to them.
3) Show Bdd Separators. This is for the BDD Framework package:
pub.dev/packages/bdd_framework.
Draws horizontal line separators above Bdd()
calls, but also between the BDD
keywords: .given(...)
, .when(...)
, .then(...)
and .example(...)()
. Also, in the BDD body you may want to separate the
implementation of the given/when/then parts. To that end, it will also add separators above
any comments that start with // Given:
, // When:
, // Then:
,
// Given/When:
or // When/Then:
. Note all these separators
are only added for files with names that start with "bdd_" or end with "_test.dart".
To configure this plugin:
- Open IntelliJ IDEA.
- For Windows, go to File -> Settings (or press
Ctrl+Alt+S
). For MacOS, go to IntelliJ IDEA -> Preferences (or pressCommand+
). - In the Settings (or Preferences) window, on the left panel, click Marcelo's Flutter/Dart Essentials.
- Configure the plugin, then click Apply, or OK to close the Settings (or Preferences) window.
You may also turn on a related native setting called "Show Method Separator":
- In the Settings (or Preferences) window, on the left panel, click to expand Editor.
- Under Editor, click to expand General.
- Under General, click on Appearance.
- On the right panel, find the checkbox Show method separators.
This plugin has my name on it, because:
-
It will provide support for the 15+ plugins that I've developed, which you can explore at https://pub.dev/publishers/glasberg.dev/packages.
-
It will incorporate features that reflect my personal preferences for IDE functionalities. While it may prioritize a specific approach and not always offer extensive customization options, you will have the flexibility to disable any features that do not align with your requirements.
Currently, this plugin only includes the ability to draw separators. However, I plan to gradually enhance its capabilities in the future.