-
-
Save parag60288/9ba1750a4b2bb3bb90a3a0ca73faa966 to your computer and use it in GitHub Desktop.
Backup of VSCode settings
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Ctrl+Shift+P > snippets > Preferences: Configure User Snippets (or add global) | |
* clean.code-snippets.json | |
*/ | |
{ | |
"Clean Architecture Controller": { | |
"prefix": "cleanController", | |
"body": [ | |
"import { Request, Response } from 'express'", | |
"", | |
"class ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} {", | |
" async handle (request: Request, response: Response): Promise<Response> {", | |
" const data = {", | |
" ...request.body,$1", | |
" ...request.params,", | |
" ...request.query,", | |
" ...request.headers,", | |
" ...request.cookies,", | |
" }", | |
"", | |
" const payload = {}", | |
"", | |
" return response.status(200).json(payload)", | |
" }", | |
"}", | |
"", | |
"export { ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} }", | |
"" | |
], | |
"description": "Clean Architecture Controller" | |
}, | |
"Clean Architecture Use Case": { | |
"prefix": "cleanUseCase", | |
"body": [ | |
"interface IRequest {}", | |
"", | |
"class ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} {", | |
" constructor () {}", | |
"", | |
" async execute (data: IRequest): Promise<void> {", | |
" $1", | |
" }", | |
"}", | |
"", | |
"export { ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} }", | |
"" | |
], | |
"description": "Clean Architecture Use Case" | |
}, | |
"Clean Architecture Repository": { | |
"prefix": "cleanRepository", | |
"body": [ | |
"class ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} implements I${TM_FILENAME_BASE/([A-Z]*[a-z]*$)//g}Repository {", | |
" constructor () {}", | |
"", | |
" async create (${TM_FILENAME_BASE/(.*)[A-Z][a-z]*/${1:/downcase}/}: ICreate${TM_FILENAME_BASE/([A-Z]*[a-z]*$)//g}DTO): Promise<number> {", | |
" $0", | |
" }", | |
"", | |
" // async findById (id: number): Promise<${TM_FILENAME_BASE/([A-Z]*[a-z]*$)//g}> {}", | |
"}", | |
"", | |
"export { ${TM_FILENAME_BASE/(.)/${1:/capitalize}/} }", | |
"" | |
], | |
"description": "Clean Architecture Repository" | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# To export the Visual Studio Code extension list, run | |
code --list-extensions | xargs -L 1 echo code --install-extension | |
# To install, just open or copy and paste to run on terminal | |
code --install-extension adpyke.vscode-sql-formatter && | |
code --install-extension anseki.vscode-color && | |
code --install-extension BeardedBear.beardedicons && | |
code --install-extension BeardedBear.beardedtheme && | |
code --install-extension bradlc.vscode-tailwindcss && | |
code --install-extension bungcip.better-toml && | |
code --install-extension christian-kohler.npm-intellisense && | |
code --install-extension christian-kohler.path-intellisense && | |
code --install-extension clinyong.vscode-css-modules && | |
code --install-extension CoenraadS.bracket-pair-colorizer-2 && | |
code --install-extension DaltonMenezes.aura-theme && | |
code --install-extension dannyconnell.split-html-attributes && | |
code --install-extension dbaeumer.vscode-eslint && | |
code --install-extension donjayamanne.githistory && | |
code --install-extension dzhavat.bracket-pair-toggler && | |
code --install-extension eamodio.gitlens && | |
code --install-extension EditorConfig.EditorConfig && | |
code --install-extension eg2.vscode-npm-script && | |
code --install-extension esbenp.prettier-vscode && | |
code --install-extension formulahendry.auto-close-tag && | |
code --install-extension formulahendry.auto-rename-tag && | |
code --install-extension foxundermoon.shell-format && | |
code --install-extension GitHub.copilot && | |
code --install-extension GitHub.copilot-labs && | |
code --install-extension Gruntfuggly.todo-tree && | |
code --install-extension humao.rest-client && | |
code --install-extension jpoissonnier.vscode-styled-components && | |
code --install-extension jrebocho.vscode-random && | |
code --install-extension juliettepretot.lucy-vscode && | |
code --install-extension kamikillerto.vscode-colorize && | |
code --install-extension kettanaito.nako && | |
code --install-extension MarkThomasMiller.sorcerer && | |
code --install-extension MaxvanderSchee.web-accessibility && | |
code --install-extension mechatroner.rainbow-csv && | |
code --install-extension meganrogge.template-string-converter && | |
code --install-extension mikestead.dotenv && | |
code --install-extension mintlify.document && | |
code --install-extension moshfeu.compare-folders && | |
code --install-extension mquandalle.graphql && | |
code --install-extension ms-azuretools.vscode-docker && | |
code --install-extension ms-python.python && | |
code --install-extension ms-python.vscode-pylance && | |
code --install-extension ms-vscode-remote.remote-containers && | |
code --install-extension ms-vscode-remote.remote-wsl && | |
code --install-extension ms-vscode.vscode-typescript-next && | |
code --install-extension mtxr.sqltools && | |
code --install-extension natqe.reload && | |
code --install-extension naumovs.color-highlight && | |
code --install-extension octref.vetur && | |
code --install-extension patbenatar.advanced-new-file && | |
code --install-extension PKief.material-icon-theme && | |
code --install-extension Prisma.prisma && | |
code --install-extension rangav.vscode-thunder-client && | |
code --install-extension ritwickdey.LiveServer && | |
code --install-extension ryuta46.multi-command && | |
code --install-extension Shinotatwu-DS.file-tree-generator && | |
code --install-extension steoates.autoimport && | |
code --install-extension streetsidesoftware.code-spell-checker && | |
code --install-extension streetsidesoftware.code-spell-checker-portuguese && | |
code --install-extension streetsidesoftware.code-spell-checker-portuguese-brazilian && | |
code --install-extension styled-components.vscode-styled-components && | |
code --install-extension tamasfe.even-better-toml && | |
code --install-extension Vue.volar && | |
code --install-extension wix.vscode-import-cost && | |
code --install-extension yzhang.markdown-all-in-one |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Ctrl+Shift+P > shortcuts | |
* Preferences: Open Keyboard Shortcuts (JSON) | |
*/ | |
[ | |
{ | |
"key": "alt+right", | |
"command": "cursorWordPartRight", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+left", | |
"command": "cursorWordPartLeft", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+shift+right", | |
"command": "cursorWordPartRightSelect", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+shift+left", | |
"command": "cursorWordPartLeftSelect", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+up", | |
"command": "editor.action.moveLinesUpAction", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+down", | |
"command": "editor.action.moveLinesDownAction", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+d", | |
"command": "editor.action.addSelectionToNextFindMatch", | |
"when": "editorFocus" | |
}, | |
{ | |
"key": "ctrl+d", | |
"command": "-editor.action.addSelectionToNextFindMatch", | |
"when": "editorFocus" | |
}, | |
{ | |
"key": "ctrl+d", | |
"command": "editor.action.copyLinesDownAction", | |
"when": "editorTextFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+shift+k", | |
"command": "-editor.action.deleteLines", | |
"when": "textInputFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+shift+x", | |
"command": "editor.action.deleteLines", | |
"when": "textInputFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+shift+d", | |
"command": "editor.action.addSelectionToNextFindMatch", | |
"when": "editorFocus" | |
}, | |
{ | |
"key": "shift+alt+down", | |
"command": "-editor.action.copyLinesDownAction", | |
"when": "editorTextFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+alt+right", | |
"command": "workbench.action.terminal.focusNextPane", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "alt+right", | |
"command": "-workbench.action.terminal.focusNextPane", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "ctrl+alt+left", | |
"command": "workbench.action.terminal.focusPreviousPane", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "alt+left", | |
"command": "-workbench.action.terminal.focusPreviousPane", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "ctrl+alt+c", | |
"command": "workbench.action.focusPanel" | |
}, | |
{ | |
"key": "ctrl+shift+alt+d", | |
"command": "workbench.view.debug" | |
}, | |
{ | |
"key": "ctrl+shift+d", | |
"command": "-workbench.view.debug" | |
}, | |
{ | |
"key": "ctrl+shift+d", | |
"command": "workbench.action.terminal.split", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "ctrl+shift+5", | |
"command": "-workbench.action.terminal.split", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "ctrl+alt+d", | |
"command": "workbench.action.positionPanelRight" | |
}, | |
{ | |
"key": "ctrl+alt+s", | |
"command": "workbench.action.positionPanelBottom" | |
}, | |
{ | |
"key": "ctrl+alt+a", | |
"command": "workbench.action.positionPanelLeft" | |
}, | |
{ | |
"key": "ctrl+alt+left", | |
"command": "workbench.action.moveEditorLeftInGroup", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+alt+right", | |
"command": "workbench.action.moveEditorRightInGroup", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+alt+left", | |
"command": "workbench.action.moveEditorToLeftGroup" | |
}, | |
{ | |
"key": "ctrl+shift+alt+right", | |
"command": "workbench.action.moveEditorToRightGroup" | |
}, | |
{ | |
"key": "ctrl+pageup", | |
"command": "workbench.action.quickOpenPreviousRecentlyUsedEditor" | |
}, | |
{ | |
"key": "ctrl+pagedown", | |
"command": "workbench.action.quickOpenLeastRecentlyUsedEditor" | |
}, | |
{ | |
"key": "ctrl+alt+down", | |
"command": "cursorColumnSelectDown", | |
"when": "textInputFocus" | |
}, | |
{ | |
"key": "ctrl+alt+up", | |
"command": "cursorColumnSelectUp", | |
"when": "textInputFocus" | |
}, | |
{ | |
"key": "ctrl+shift+alt+down", | |
"command": "editor.action.insertCursorBelow", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+alt+up", | |
"command": "editor.action.insertCursorAbove", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+/", | |
"command": "editor.action.blockComment", | |
"when": "editorTextFocus && !editorReadonly" | |
}, | |
// { // uncomment on linux | |
// "key": "ctrl+shift+;", | |
// "command": "editor.action.blockComment", | |
// "when": "editorTextFocus && !editorReadonly" | |
// }, | |
// { // uncomment on linux | |
// "key": "ctrl+;", | |
// "command": "editor.action.commentLine", | |
// "when": "editorTextFocus && !editorReadonly" | |
// }, | |
// { // uncomment on linux | |
// "key": "ctrl+/", | |
// "command": "-editor.action.commentLine", | |
// "when": "editorTextFocus && !editorReadonly" | |
// }, | |
{ | |
"key": "ctrl+'", | |
"command": "workbench.action.terminal.toggleTerminal" | |
}, | |
{ | |
"key": "ctrl+shift+[BracketLeft]", | |
"command": "-workbench.action.terminal.toggleTerminal" | |
}, | |
{ | |
"key": "ctrl+alt+p", | |
"command": "workbench.action.gotoSymbol" | |
}, | |
{ | |
"key": "ctrl+shift+o", | |
"command": "-workbench.action.gotoSymbol" | |
}, | |
{ | |
"key": "ctrl+shift+o", | |
"command": "workbench.action.openRecent" | |
}, | |
{ | |
"key": "ctrl+r", | |
"command": "-workbench.action.openRecent" | |
}, | |
{ | |
"key": "ctrl+shift+r", | |
"command": "workbench.action.files.revert" | |
}, | |
{ | |
"key": "alt+shift+p", | |
"command": "parameterHints.toggle" | |
}, | |
{ | |
"key": "ctrl+shift+enter", | |
"command": "workbench.action.toggleMaximizedPanel" | |
}, | |
{ | |
"key": "shift+enter", | |
"command": "workbench.action.terminal.toggleTerminal" | |
}, | |
{ | |
"key": "shift+enter", | |
"command": "workbench.action.focusActiveEditorGroup", | |
"when": "terminalFocus" | |
}, | |
{ | |
"key": "ctrl+enter", | |
"command": "workbench.action.togglePanel" | |
}, | |
{ | |
"key": "ctrl+enter", | |
"command": "-github.copilot.generate", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+c", | |
"command": "github.copilot.generate", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+x", | |
"command": "editor.action.inlineSuggest.trigger", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+shift+c", | |
"command": "toggleFindCaseSensitive", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+a", | |
"command": "editor.emmet.action.balanceOut" | |
}, | |
{ | |
"key": "ctrl+shift+z", | |
"command": "editor.emmet.action.balanceIn" | |
}, | |
{ | |
"key": "ctrl+oem_period", | |
"command": "-docs.write" | |
}, | |
{ | |
"key": "alt+oem_period", | |
"command": "docs.write", | |
"when": "editorTextFocus && config.docwriter.hotkey.windows == 'Ctrl + .' && editorLangId =~ /typescript|javascript|python|php|java/" | |
}, | |
{ | |
"key": "ctrl+shift+alt+c", | |
"command": "extension.colorHelper.convert", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+shift+e", | |
"command": "remote-wsl.revealInExplorer", | |
"when": "editorTextFocus && remoteName == 'wsl'" | |
}, | |
{ | |
"key": "alt+shift+r", | |
"command": "workbench.files.action.showActiveFileInExplorer", | |
"when": "editorTextFocus || explorerViewletFocus" | |
}, | |
{ | |
"key": "alt+shift+t", | |
"command": "workbench.files.action.collapseExplorerFolders", | |
"when": "editorTextFocus || explorerViewletFocus" | |
}, | |
{ | |
"key": "alt+c c", | |
"command": "-extension.colorHelper.convert", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "ctrl+shift+alt+p", | |
"command": "extension.colorHelper.pick", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "alt+c p", | |
"command": "-extension.colorHelper.pick", | |
"when": "editorTextFocus" | |
}, | |
{ | |
"key": "shift+alt+f", | |
"command": "extension.multiCommand.execute", | |
"interval": 100, | |
"args": { | |
"sequence": [ | |
// "headwind.sortTailwindClasses", | |
"editor.action.formatDocument", | |
"eslint.executeAutofix" | |
] | |
}, | |
"when": "editorTextFocus && !editorReadonly && !inCompositeEditor" | |
}, | |
{ | |
"key": "shift+alt+g", | |
"command": "editor.action.formatDocument", | |
"when": "editorHasDocumentFormattingProvider && editorTextFocus && !editorReadonly && !inCompositeEditor" | |
}, | |
// { | |
// "key": "shift+alt+d", | |
// "command": "extension.multiCommand.execute", | |
// "args": { | |
// "sequence": ["extension.splitHTMLAttributes", "eslint.executeAutofix"] | |
// }, | |
// "when": "editorTextFocus && !editorReadonly && !inCompositeEditor" | |
// }, | |
{ | |
"key": "shift+alt+d", | |
"command": "eslint.executeAutofix", | |
"when": "editorTextFocus && !editorReadonly && !inCompositeEditor" | |
}, | |
{ | |
"key": "shift+alt+x", | |
"command": "extension.splitHTMLAttributes", | |
"when": "editorTextFocus && !editorReadonly && !inCompositeEditor" | |
}, | |
{ | |
"key": "shift+alt+s", | |
"command": "editor.action.organizeImports", | |
"when": "editorTextFocus && !editorReadonly && !inCompositeEditor" | |
}, | |
{ | |
"key": "shift+alt+a", | |
"command": "editor.action.sourceAction", | |
"args": { | |
"kind": "source.addMissingImports", | |
"apply": "first" | |
} | |
}, | |
{ | |
"key": "shift+alt+a", | |
"command": "git.stageSelectedRanges", | |
"when": "isInDiffEditor" | |
}, | |
{ | |
"key": "shift+alt+s", | |
"command": "git.unstageSelectedRanges", | |
"when": "isInDiffEditor" | |
}, | |
{ | |
"key": "ctrl+n", | |
"command": "extension.advancedNewFile" | |
}, | |
{ | |
"key": "ctrl+alt+n", | |
"command": "-extension.advancedNewFile" | |
}, | |
{ | |
"key": "ctrl+t", | |
"command": "workbench.action.files.newUntitledFile" | |
}, | |
{ | |
"key": "ctrl+n", | |
"command": "-workbench.action.files.newUntitledFile" | |
}, | |
{ | |
"key": "ctrl+alt+t", | |
"command": "workbench.action.showAllSymbols" | |
}, | |
{ | |
"key": "ctrl+t", | |
"command": "-workbench.action.showAllSymbols" | |
}, | |
{ | |
"key": "ctrl+alt+b", | |
"command": "workbench.action.tasks.build" | |
}, | |
{ | |
"key": "ctrl+shift+b", | |
"command": "-workbench.action.tasks.build" | |
}, | |
{ | |
"key": "ctrl+shift+b", | |
"command": "workbench.action.toggleActivityBarVisibility" | |
}, | |
{ | |
"key": "ctrl+tab", | |
"command": "workbench.action.nextEditor" | |
}, | |
{ | |
"key": "ctrl+shift+tab", | |
"command": "workbench.action.previousEditor" | |
}, | |
{ | |
"key": "alt+shift+q", | |
"command": "workbench.action.quickOpenLeastRecentlyUsedEditor" | |
}, | |
{ | |
"key": "alt+q", | |
"command": "workbench.action.quickOpenPreviousRecentlyUsedEditor" | |
}, | |
{ | |
"key": "alt+q", | |
"command": "workbench.action.quickOpenNavigateNextInEditorPicker", | |
"when": "inEditorsPicker && inQuickOpen" | |
}, | |
{ | |
"key": "alt+shift+q", | |
"command": "workbench.action.quickOpenNavigatePreviousInEditorPicker", | |
"when": "inEditorsPicker && inQuickOpen" | |
}, | |
{ | |
"key": "alt+a", | |
"command": "remote-containers.attachToRunningContainer" | |
}, | |
{ | |
"key": "alt+delete", | |
"command": "deleteWordRight", | |
"when": "textInputFocus && !editorReadonly" | |
}, | |
{ | |
"key": "alt+backspace", | |
"command": "deleteWordLeft", | |
"when": "textInputFocus && !editorReadonly" | |
}, | |
{ | |
"key": "ctrl+shift+]", | |
"command": "editor.fold", | |
"when": "editorTextFocus && foldingEnabled" | |
}, | |
{ | |
"key": "ctrl+shift+\\", | |
"command": "editor.unfold", | |
"when": "editorTextFocus && foldingEnabled" | |
}, | |
{ | |
"key": "ctrl+shift+s", | |
"command": "-workbench.action.files.saveAs" | |
}, | |
{ | |
"key": "ctrl+shift+s", | |
"command": "workbench.action.files.saveWithoutFormatting" | |
}, | |
{ | |
"key": "tab", | |
"command": "-markdown.extension.onTabKey", | |
"when": "editorTextFocus && !editorReadonly && !editorTabMovesFocus && !hasOtherSuggestions && !hasSnippetCompletions && !inSnippetMode && !suggestWidgetVisible && editorLangId == 'markdown'" | |
}, | |
{ | |
"key": "alt+1", | |
"command": "workbench.view.explorer" | |
}, | |
{ | |
"key": "alt+1", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.explorer'" | |
}, | |
{ | |
"key": "alt+2", | |
"command": "workbench.view.scm" | |
}, | |
{ | |
"key": "alt+2", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.scm'" | |
}, | |
{ | |
"key": "alt+3", | |
"command": "workbench.view.search" | |
}, | |
{ | |
"key": "alt+3", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.search'" | |
}, | |
{ | |
"key": "alt+4", | |
"command": "workbench.view.debug" | |
}, | |
{ | |
"key": "alt+4", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.debug'" | |
}, | |
{ | |
"key": "alt+5", | |
"command": "workbench.view.extensions" | |
}, | |
{ | |
"key": "alt+5", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.extensions'" | |
}, | |
{ | |
"key": "alt+6", | |
"command": "workbench.view.extension.gitlens" | |
}, | |
{ | |
"key": "alt+6", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.extension.gitlens'" | |
}, | |
{ | |
"key": "alt+7", | |
"command": "workbench.view.extension.dockerView" | |
}, | |
{ | |
"key": "alt+7", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.extension.dockerView'" | |
}, | |
{ | |
"key": "alt+8", | |
"command": "workbench.view.remote" | |
}, | |
{ | |
"key": "alt+8", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.remote'" | |
}, | |
{ | |
"key": "alt+9", | |
"command": "workbench.view.extension.foldersCompare" | |
}, | |
{ | |
"key": "alt+9", | |
"command": "workbench.action.toggleSidebarVisibility", | |
"when": "activeViewlet == 'workbench.view.extension.foldersCompare'" | |
}, | |
// Disable default ALT commands | |
{ | |
"key": "alt+1", | |
"command": "-workbench.action.openEditorAtIndex1" | |
}, | |
{ | |
"key": "alt+2", | |
"command": "-workbench.action.openEditorAtIndex2" | |
}, | |
{ | |
"key": "alt+3", | |
"command": "-workbench.action.openEditorAtIndex3" | |
}, | |
{ | |
"key": "alt+4", | |
"command": "-workbench.action.openEditorAtIndex4" | |
}, | |
{ | |
"key": "alt+5", | |
"command": "-workbench.action.openEditorAtIndex5" | |
}, | |
{ | |
"key": "alt+6", | |
"command": "-workbench.action.openEditorAtIndex6" | |
}, | |
{ | |
"key": "alt+7", | |
"command": "-workbench.action.openEditorAtIndex7" | |
}, | |
{ | |
"key": "alt+8", | |
"command": "-workbench.action.openEditorAtIndex8" | |
}, | |
{ | |
"key": "alt+9", | |
"command": "-workbench.action.openEditorAtIndex9" | |
} | |
] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Ctrl+Shift+P > snippets > Preferences: Configure User Snippets | |
* next.code-snippets.json | |
*/ | |
{ | |
"clsx": { | |
"prefix": "xx", | |
"body": ["className={clsx(", "'$0',", "'',", ")}"], | |
"description": "Join classnames: clsx library" | |
}, | |
"className": { | |
"prefix": "cc", | |
"body": ["className=\"$0\""], | |
"description": "React className" | |
}, | |
"style": { | |
"prefix": "ww", | |
"body": ["style={tw`$0`}"], | |
"description": "React Native style" | |
}, | |
"tailwind": { | |
"prefix": "ss", | |
"body": ["style={tw(\"$0\")}"], | |
"description": "React Native style" | |
}, | |
"Next.js Component": { | |
"prefix": "nextComponent", | |
"body": [ | |
"export function ${1:${TM_FILENAME_BASE}} () {", | |
" return (", | |
" <>", | |
" <h1>${2:${TM_FILENAME_BASE}}</h1>", | |
" </>", | |
" )", | |
"}", | |
"" | |
], | |
"description": "Next.js Component" | |
}, | |
"Next.js Page": { | |
"prefix": "nextPage", | |
"body": [ | |
"export default function ${1:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}} () {", | |
" return (", | |
" <>", | |
" <h1>${2:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}}</h1>", | |
" </>", | |
" )", | |
"}", | |
"" | |
], | |
"description": "Next.js Page" | |
}, | |
"Next.js Server Page": { | |
"prefix": "nextServer", | |
"body": [ | |
"import type { GetServerSideProps } from 'next'", | |
"", | |
"export default function ${1:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}} ({ cookies }: any) {", | |
" return (", | |
" <>", | |
" <pre>{JSON.stringify(cookies, null, 2)}$0</pre>", | |
" </>", | |
" )", | |
"}", | |
"", | |
"export const getServerSideProps: GetServerSideProps = async ({", | |
" params,", | |
" req,", | |
" query", | |
"}) => {", | |
" // const { slug, id } = params", | |
" // const { page, perPage } = query", | |
"", | |
" const { cookies } = req // { token, refreshToken } = req.cookies", | |
" return {", | |
" // notFound: true,", | |
" props: { cookies }", | |
" }", | |
"}", | |
"" | |
], | |
"description": "Next.js Server Page" | |
}, | |
"Next.js Static Page": { | |
"prefix": "nextStatic", | |
"body": [ | |
"import type { GetStaticPaths, GetStaticProps } from 'next'", | |
"import { ParsedUrlQuery } from 'querystring'", | |
"", | |
"export default function ${1:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}} ({ id, currentHour }: any) {", | |
" return (", | |
" <>", | |
" <h1>Page ID: {id}</h1>", | |
" <h2>Current hour: {currentHour}$0</h2>", | |
" </>", | |
" )", | |
"}", | |
"", | |
"export const getStaticPaths: GetStaticPaths = async () => {", | |
" return {", | |
" paths: [", | |
" // { params: { id: '1' } },", | |
" // { params: { id: '2' } },", | |
" // { params: { id: '3' } }", | |
" ],", | |
" // fallback: false // false pre-rendered just the paths and the rest is never showed", | |
" // fallback: true // true forces paths to be pre-rendered and the rest is generated on demand", | |
" fallback: 'blocking' // blocking does not need to have paths because all paths are generated on demand", | |
" }", | |
"}", | |
"", | |
"export const getStaticProps: GetStaticProps = async ({ params }) => {", | |
" const { id } = params as ParsedUrlQuery", | |
" const currentHour = new Date().toLocaleTimeString('en-US', {", | |
" hour: '2-digit',", | |
" minute: '2-digit',", | |
" second: '2-digit',", | |
" hour12: false", | |
" })", | |
"", | |
" return {", | |
" // notFound: true,", | |
" // redirect: {", | |
" // destination: '/',", | |
" // permanent: false", | |
" // },", | |
" props: { id, currentHour },", | |
" revalidate: 60 * 1 // 1 minute", | |
" }", | |
"}", | |
"" | |
], | |
"description": "Next.js Static Page" | |
}, | |
"Next.js API": { | |
"prefix": "nextAPI", | |
"body": [ | |
"import type { NextApiRequest, NextApiResponse } from 'next'", | |
"", | |
"type ResponseData = any;", | |
"", | |
"export default async function ${1:${TM_FILENAME_BASE/(.*)/${1:/pascalcase}/}} (", | |
" req: NextApiRequest,", | |
" res: NextApiResponse<ResponseData>", | |
") {", | |
" const { id, page } = req.query // /5?page=20", | |
" const { method, url, cookies } = req", | |
"", | |
" // res.setHeader('Cache-Control', 's-maxage=30, stale-while-revalidate') // cache for 30 seconds", | |
"", | |
" res.status(200).json({", | |
" message: '${2:Hello, API!}',", | |
" id, // 5", | |
" page, // 20", | |
" method,", | |
" url,", | |
" cookies,", | |
" headers: req.headers", | |
" })", | |
" // res.status(500).send({ error: 'failed to fetch data' })", | |
" // res.redirect(307, '/')", | |
"}", | |
"" | |
], | |
"description": "Next.js API" | |
}, | |
"Next.js Context": { | |
"prefix": "nextContext", | |
"body": [ | |
"import { createContext, PropsWithChildren, useContext } from 'react'", | |
"", | |
"interface ${TM_FILENAME_BASE}Props {${1:", | |
" // doSomething(): Promise<void>;", | |
" // isTrue: boolean;", | |
" // info: Info | undefined;", | |
"}}", | |
"", | |
"export const ${TM_FILENAME_BASE} = createContext({} as ${TM_FILENAME_BASE}Props)", | |
"", | |
"export function ${TM_FILENAME_BASE/([A-Z]*[a-z]*$)//g}Provider({ children }: PropsWithChildren) {${2:", | |
" // const [info, setInfo] = useState<Info>()", | |
" // const [isTrue, setIsTrue] = useState(false)", | |
" // const doSomething = async () => {}", | |
" $0", | |
"", | |
" return (", | |
" <${TM_FILENAME_BASE}.Provider value={{${3: /* doSomething, isTrue, info */ }}}>", | |
" {children}", | |
" </${TM_FILENAME_BASE}.Provider>", | |
" )", | |
"}", | |
"", | |
"export function use${TM_FILENAME_BASE/([A-Z]*[a-z]*$)//g}() {", | |
" return useContext(${TM_FILENAME_BASE})", | |
"}", | |
"" | |
], | |
"description": "Next.js Context" | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Ctrl+Shift+P > settings | |
* Preferences: Open Settings (JSON) | |
*/ | |
{ | |
// Visual settings | |
"workbench.colorTheme": "Sorcerer", | |
"editor.fontFamily": "'Rec Mono Casual', 'Cascadia Code', 'Operator Mono Lig', 'Fira Code', 'SF Mono', 'Ubuntu Mono', Consolas, monospace", // Operator Mono Lig: https://drive.google.com/open?id=17o8KnqYo74QlA3lNDQg7ZrigiqJbND8q | |
// "terminal.integrated.shell.osx": "/bin/zsh", | |
"terminal.integrated.fontSize": 16, | |
"editor.fontSize": 15, | |
"editor.lineHeight": 21, | |
"editor.fontWeight": "200", | |
"editor.fontLigatures": true, | |
"editor.tabSize": 2, | |
"editor.rulers": [80, 120], | |
// "editor.codeActionsOnSave": { | |
// "source.fixAll.eslint": true | |
// }, | |
// "editor.formatOnSave": true, | |
"editor.suggestOnTriggerCharacters": false, | |
"editor.quickSuggestions": { | |
"other": false, | |
"comments": false, | |
"strings": false | |
}, | |
"editor.mouseWheelZoom": true, | |
"editor.minimap.enabled": false, | |
"editor.renderWhitespace": "boundary", | |
"editor.suggestSelection": "first", | |
// "editor.wordWrap": "on", | |
// "editor.formatOnPaste": true, | |
"editor.cursorBlinking": "smooth", | |
"editor.semanticHighlighting.enabled": false, | |
"editor.renderLineHighlight": "gutter", | |
"editor.parameterHints.enabled": false, | |
// Workbench settings | |
"workbench.editor.enablePreview": false, | |
"workbench.editor.wrapTabs": false, | |
"workbench.editor.labelFormat": "short", | |
"workbench.editor.enablePreviewFromQuickOpen": false, | |
"workbench.startupEditor": "newUntitledFile", | |
"security.workspace.trust.untrustedFiles": "open", | |
"breadcrumbs.enabled": true, | |
"explorer.compactFolders": false, | |
"explorer.confirmDragAndDrop": false, | |
"explorer.autoReveal": false, | |
"explorer.confirmDelete": false, | |
// Ignore files/folders | |
"files.exclude": { | |
"node_modules": true, | |
".next": true, | |
".nuxt": true, | |
".expo": true, | |
".expo-shared": true, | |
".vscode": true | |
}, | |
// Extensions | |
"prettier.printWidth": 80, | |
// "prettier.printWidth": 120, | |
"extensions.ignoreRecommendations": true, | |
"git.enableSmartCommit": true, | |
"gitlens.codeLens.recentChange.enabled": false, | |
"gitlens.codeLens.authors.enabled": false, | |
"gitlens.codeLens.enabled": false, | |
"gitlens.views.repositories.branches.layout": "list", | |
"cSpell.language": "en,pt,pt_BR", | |
"scss.lint.unknownAtRules": "ignore", | |
// "bracket-pair-colorizer-2.colors": [ | |
// "#D39E17", | |
// "#A15DEF", | |
// "#3398DB" | |
// ], | |
// Languages | |
"javascript.updateImportsOnFileMove.enabled": "never", | |
"typescript.updateImportsOnFileMove.enabled": "never", | |
"javascript.suggest.autoImports": true, | |
"typescript.suggest.autoImports": true, | |
"emmet.syntaxProfiles": { | |
"javascript": "jsx" | |
}, | |
"emmet.includeLanguages": { | |
"javascript": "javascriptreact" | |
}, | |
"[dockerfile]": { | |
"editor.defaultFormatter": "foxundermoon.shell-format" | |
}, | |
// "editor.inlineSuggest.enabled": false, // this disable copilot | |
"github.copilot.enable": { | |
"*": true, | |
"yaml": true, | |
"plaintext": true, | |
"markdown": true, | |
"typescript": true, | |
"javascript": true | |
}, | |
"gitlens.advanced.messages": { | |
"suppressGitMissingWarning": true | |
}, | |
"git.ignoreMissingGitWarning": true, | |
"[jsonc]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[json]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[typescript]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[markdown]": { | |
"editor.defaultFormatter": "yzhang.markdown-all-in-one" | |
}, | |
"[scss]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[javascriptreact]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[typescriptreact]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[html]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"[javascript]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"cSpell.userWords": [ | |
"adonisjs", | |
"apexcharts", | |
"automock", | |
"callees", | |
"camelcase", | |
"Casefold", | |
"chakra", | |
"classname", | |
"cloudflare", | |
"cloudflareworkers", | |
"clsx", | |
"codegen", | |
"Colab", | |
"Colaboratory", | |
"darkmode", | |
"Dashgo", | |
"dataproxy", | |
"datepicker", | |
"dayjs", | |
"deliveryapp", | |
"dtos", | |
"embeddable", | |
"Embeddable", | |
"envfile", | |
"esbuild", | |
"esnext", | |
"extralight", | |
"faunadb", | |
"flagpack", | |
"flowbite", | |
"hasura", | |
"hookform", | |
"Howto", | |
"iconify", | |
"ignews", | |
"immer", | |
"importify", | |
"isready", | |
"itty", | |
"jose", | |
"jwks", | |
"killall", | |
"kuch", | |
"kuchak", | |
"lcov", | |
"linebreak", | |
"linkedin", | |
"LINKEDIN", | |
"maniatests", | |
"maxage", | |
"mercadodigital", | |
"metafile", | |
"Metafile", | |
"middlewares", | |
"miniflare", | |
"miragejs", | |
"mischka", | |
"mkdir", | |
"monospace", | |
"mysqladmin", | |
"nativewind", | |
"nestjs", | |
"neuralmind", | |
"nextauth", | |
"nextjs", | |
"openapi", | |
"originalname", | |
"outdir", | |
"outfile", | |
"overscan", | |
"paren", | |
"pgadmin", | |
"pinia", | |
"Pinia", | |
"pkill", | |
"pokemon", | |
"pokemons", | |
"Pokemons", | |
"postgres", | |
"preconnect", | |
"prefetch", | |
"pressable", | |
"Pressable", | |
"prettierrc", | |
"prismic", | |
"PRISMIC", | |
"prismicio", | |
"ratelimit", | |
"referrerpolicy", | |
"rentacar", | |
"respawn", | |
"Roboto", | |
"scrollbars", | |
"semibold", | |
"serializers", | |
"sgit", | |
"signin", | |
"signout", | |
"sulsans", | |
"tailwindcss", | |
"tanstack", | |
"textnodes", | |
"themesberg", | |
"tsnd", | |
"tsndr", | |
"tsyringe", | |
"tulpn", | |
"twrnc", | |
"typedefs", | |
"typeorm", | |
"unmocked", | |
"unstyled", | |
"upsert", | |
"usecase", | |
"uuidv", | |
"valtio", | |
"Vercel", | |
"Videoblogging", | |
"vitedge", | |
"vueuse", | |
"Whishlist", | |
"woodsmoke", | |
"xaxis", | |
"youtube", | |
"zustand" | |
], | |
"[dockercompose]": { | |
"editor.defaultFormatter": "ms-azuretools.vscode-docker" | |
}, | |
"bracket-pair-colorizer-2.depreciation-notice": false, | |
"http.systemCertificates": false, | |
"workbench.colorCustomizations": { | |
"parameterHints.hintBackground": "#25374a50", | |
"parameterHints.hintForeground": "#6e7d9a" | |
}, | |
"parameterHints.hintingType": "variableOnly", | |
"editor.inlineSuggest.enabled": true, | |
"[handlebars]": { | |
"editor.defaultFormatter": "vscode.html-language-features" | |
}, | |
"workbench.iconTheme": "material-icon-theme", | |
"editor.accessibilitySupport": "off", | |
"editor.bracketPairColorization.enabled": true, | |
"[css]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"npm.keybindingsChangedWarningShown": true, | |
"css.lint.unknownAtRules": "ignore", | |
"splitHTMLAttributes.closingBracketOnNewLine": true, | |
"parameterHints.enabled": false, | |
"[vue]": { | |
"editor.defaultFormatter": "esbenp.prettier-vscode" | |
}, | |
"workbench.activityBar.visible": false | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Ctrl+Shift+P > snippets > vue.json | |
* Preferences: Configure User Snippets | |
* ~/.config/Code/User/snippets/vue.json | |
*/ | |
{ | |
"Vue template": { | |
"prefix": "vue", | |
"body": [ | |
"<template>", | |
" $0", | |
"</template>" | |
"", | |
"<script>", | |
"// import { onBeforeMount, onMounted, computed, ref, reactive } from 'vue'", | |
"", | |
"export default {", | |
" setup() {", | |
" ", | |
" ", | |
" return {", | |
" ", | |
" }", | |
" }", | |
"}", | |
"</script>", | |
"", | |
"<style lang=\"scss\" scoped>", | |
"", | |
"</style>", | |
], | |
"description": "Vue template" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment