From b57f601e1b869a72ff51addf8926644c0d2fb7d5 Mon Sep 17 00:00:00 2001 From: jeffvli Date: Mon, 24 Jul 2023 14:37:42 -0700 Subject: [PATCH] Add css modules extensions --- .vscode/extensions.json | 3 ++- .vscode/settings.json | 32 +++++++++++++++++++++++++++++--- 2 files changed, 31 insertions(+), 4 deletions(-) diff --git a/.vscode/extensions.json b/.vscode/extensions.json index b096b192..c10cabc4 100644 --- a/.vscode/extensions.json +++ b/.vscode/extensions.json @@ -4,6 +4,7 @@ "EditorConfig.EditorConfig", "stylelint.vscode-stylelint", "esbenp.prettier-vscode", - "clinyong.vscode-css-modules" + "clinyong.vscode-css-modules", + "Huuums.vscode-fast-folder-structure" ] } diff --git a/.vscode/settings.json b/.vscode/settings.json index 9630bed6..44e780be 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -19,8 +19,8 @@ "css.validate": true, "less.validate": false, "scss.validate": true, - "scss.lint.unknownAtRules": "warn", - "scss.lint.unknownProperties": "warn", + "scss.lint.unknownAtRules": "warning", + "scss.lint.unknownProperties": "warning", "javascript.validate.enable": false, "javascript.format.enable": false, "typescript.format.enable": false, @@ -42,5 +42,31 @@ "typescript.updateImportsOnFileMove.enabled": "always", "[typescript]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[typescriptreact]": { "editor.defaultFormatter": "esbenp.prettier-vscode" }, - "typescript.format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": true + "typescript.format.insertSpaceAfterOpeningAndBeforeClosingTemplateStringBraces": true, + "folderTemplates.structures": [ + { + "name": "TypeScript Feature Component With CSS Modules", + "omitParentDirectory": true, + "structure": [ + { + "fileName": ".tsx", + "template": "Functional Component with CSS Modules" + }, + { + "fileName": ".module.scss" + } + ] + } + ], + "folderTemplates.fileTemplates": { + "Functional Component with CSS Modules": [ + "import styles from './.module.scss';", + "", + "interface Props {}", + "", + "export const = ({}: Props) => {", + " return
;", + "};" + ] + } }