Plugin: Awesome Console
Install this plugin to be able to click on a file path within the console.
Macro
Setting up a macro which will fix all the linting issues, optimizes the imports and runs Prettier.
-
StyleLint
- Setup a file watcher
(fix action not yet
supported) with
- File Type:
SCSS style sheet - Scope:
Current File - Program:
$ProjectFileDir$/node_modules/.bin/stylelint - Arguments:
$FileName$ --fix - Working Dir:
$FileDir$ - Advanced Options: None, all deactivated
- File Type:
- Setup a file watcher
(fix action not yet
supported) with
-
Record macro (Edit > Macros > Start Macro Recording) in this order
- Action: TsLintFileFixAction (with opened *.ts file)
- Action: OptimizeImports
- Action: ReformatWithPrettierAction
- Action: FileWatcher.runForFiles (with opened *.scss file)
- Action: SaveAll
-
Save macro as e.g.
Fix & Save -
Assign Keyboard shortcut
Ctrl+Sto macroFix & Save(search for macro)