@@ -15,6 +15,34 @@ local utils = lazy.require("flutter-tools.utils") ---@module "flutter-tools.util
1515--- @field web_port ? string
1616--- @field cwd ? string full path of current working directory , defaults to LSP root
1717--- @field additional_args ? string[] additional arguments to pass to the flutter run command
18+ ---
19+ --- @class flutter.DevLogOpts
20+ --- @field filter ? fun ( data : string ): boolean
21+ --- @field enabled ? boolean
22+ --- @field notify_errors ? boolean
23+ --- @field focus_on_open ? boolean
24+ --- @field open_cmd ? string
25+ ---
26+ --- @class flutter.RunArgsOpts
27+ --- @field flutter ? table | string -- options applied to ` flutter run` command
28+ --- @field dart ? table | string -- options appliert to ` dart run` command
29+ ---
30+ --- @class flutter.Config
31+ --- @field flutter_path ? string Path to the Flutter SDK
32+ --- @field flutter_lookup_cmd ? string Command to find Flutter SDK
33+ --- @field pre_run_callback ? fun ( opts : table ) Function called before running Flutter
34+ --- @field root_patterns ? string[] Patterns to find project root
35+ --- @field fvm ? boolean Whether to use FVM (Flutter Version Manager )
36+ --- @field default_run_args ? flutter.RunArgsOpts Default options for run command
37+ --- @field widget_guides ? { enabled : boolean , debug : boolean }
38+ --- @field ui ? { border : string }
39+ --- @field decorations ? { statusline : { app_version : boolean , device : boolean , project_config : boolean }}
40+ --- @field debugger ? { enabled : boolean , exception_breakpoints ?: table , evaluate_to_string_in_debug_views ?: boolean , register_configurations ?: fun ( paths : table )}
41+ --- @field closing_tags ? { highlight : string , prefix : string , priority : number , enabled : boolean }
42+ --- @field lsp ? { debug ?: number , color ?: { enabled : boolean , background : boolean , foreground : boolean , virtual_text : boolean , virtual_text_str : string , background_color ?: string }, settings ?: table }
43+ --- @field outline ? { auto_open : boolean , open_cmd ?: string }
44+ --- @field dev_log ? flutter.DevLogOpts
45+ --- @field dev_tools ? { autostart : boolean , auto_open_browser : boolean }
1846
1947local M = {}
2048
@@ -67,13 +95,13 @@ M.debug_levels = {
6795 DEBUG = 1 ,
6896 WARN = 2 ,
6997}
70-
7198local config = {
7299 flutter_path = nil ,
73100 flutter_lookup_cmd = get_default_lookup (),
74101 pre_run_callback = nil ,
75102 root_patterns = { " .git" , " pubspec.yaml" },
76103 fvm = false ,
104+ default_run_args = nil ,
77105 widget_guides = {
78106 enabled = false ,
79107 debug = false ,
0 commit comments