From 8bbf2284ba9b6224aab778209eea0454b89c0971 Mon Sep 17 00:00:00 2001 From: eric Date: Tue, 7 May 2024 17:12:02 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E6=96=87=E4=BB=B6=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../hooks/React_hooks--useContext.md | 0 .../React_hooks--useEffect&useLayoutEffect.md | 0 .../hooks/React_hooks--useMemo&useCallback.md | 0 .../{ => react}/hooks/React_hooks--useRef.md | 0 .../hooks/React_hooks--useState&useReducer.md | 0 ...17\345\214\226\345\273\272\350\256\256.md" | 68 ++++---- .../{study => z-study}/java/base/java_1.md | 0 .../{study => z-study}/java/base/java_10.md | 0 .../{study => z-study}/java/base/java_11.md | 0 .../{study => z-study}/java/base/java_12.md | 0 .../{study => z-study}/java/base/java_13.md | 0 .../{study => z-study}/java/base/java_14.md | 0 .../{study => z-study}/java/base/java_2.md | 0 .../{study => z-study}/java/base/java_3.md | 0 .../{study => z-study}/java/base/java_4.md | 0 .../{study => z-study}/java/base/java_5.md | 0 .../{study => z-study}/java/base/java_6.md | 0 .../{study => z-study}/java/base/java_7.md | 0 .../{study => z-study}/java/base/java_8.md | 0 .../{study => z-study}/java/base/java_9.md | 0 .../java/mybatis/image-1.png | Bin .../java/mybatis/image-2.png | Bin .../{study => z-study}/java/mybatis/image.png | Bin .../java/mybatis/mybatis.md | 0 .../java/mybatis/mybatis_plus.md | 0 .../java/spring/spring_1.md | 0 content/posts/{study => z-study}/lerna.md | 0 .../z-study/linux\345\237\272\347\241\200.md" | 0 .../posts/{study => z-study}/mysql/JDBC.md | 0 .../posts/{study => z-study}/mysql/mysql_1.md | 0 .../posts/{study => z-study}/mysql/mysql_2.md | 0 .../posts/{study => z-study}/mysql/mysql_3.md | 0 ...13\350\221\261\346\250\241\345\236\213.md" | 0 .../node/node\345\237\272\347\241\200.md" | 0 ...de\347\232\204\347\211\271\347\202\271.md" | 0 .../node/small_node/index.js | 0 .../node/small_node/requestHandler.js | 0 .../node/small_node/route.js | 0 .../node/small_node/server.js | 0 content/posts/{study => z-study}/rollup.md | 0 .../z-study/shell\345\237\272\347\241\200.md" | 0 ...44\350\241\214\345\267\245\345\205\267.md" | 0 public/babel/index.html | 8 +- public/categories/index.xml | 4 +- public/categories/react-hooks/index.html | 12 -- public/categories/react-hooks/index.xml | 57 +------ public/categories/study-notes/index.html | 9 -- public/categories/study-notes/index.xml | 48 +----- "public/commonjs\345\222\214esm/index.html" | 4 +- public/index.json | 2 +- public/index.xml | 146 ++++++++---------- .../index.html" | 4 +- public/mysql_2/index.html | 12 +- public/mysql_3/index.html | 8 +- public/new_life/index.html | 6 +- .../node\345\237\272\347\241\200/index.html" | 6 +- public/posts/index.html | 48 +++--- public/posts/index.xml | 146 ++++++++---------- public/posts/page/2/index.html | 54 +++---- public/posts/page/3/index.html | 74 ++++----- public/posts/page/4/index.html | 39 ----- public/posts/z-study/node/small_node/route.js | 12 ++ .../index.html | 14 +- public/series/format/index.html | 7 +- public/series/format/index.xml | 18 +-- public/series/hooks/index.html | 12 -- public/series/hooks/index.xml | 57 +------ public/series/index.xml | 18 +-- public/series/mysql/index.html | 6 - public/series/mysql/index.xml | 32 +--- .../shell\345\237\272\347\241\200/index.html" | 6 +- public/sitemap.xml | 31 ++-- public/tags/cli/index.html | 7 +- public/tags/cli/index.xml | 18 +-- public/tags/index.html | 2 +- public/tags/index.xml | 30 ++-- public/tags/linux/index.html | 3 - public/tags/linux/index.xml | 12 -- public/tags/mac/index.html | 3 - public/tags/mac/index.xml | 12 -- public/tags/node/index.html | 11 +- public/tags/node/index.xml | 41 +---- public/tags/rollup/index.html | 7 +- public/tags/rollup/index.xml | 21 +-- .../index.html" | 88 +++++------ .../index.md" | 68 ++++---- .../index.html" | 6 +- .../index.html" | 4 +- .../index.html" | 8 +- .../index.html" | 4 +- .../index.html" | 4 +- 91 files changed, 426 insertions(+), 891 deletions(-) rename content/posts/{ => react}/hooks/React_hooks--useContext.md (100%) rename content/posts/{ => react}/hooks/React_hooks--useEffect&useLayoutEffect.md (100%) rename content/posts/{ => react}/hooks/React_hooks--useMemo&useCallback.md (100%) rename content/posts/{ => react}/hooks/React_hooks--useRef.md (100%) rename content/posts/{ => react}/hooks/React_hooks--useState&useReducer.md (100%) rename "content/posts/tool/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" => "content/posts/z-drafts/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" (67%) rename content/posts/{study => z-study}/java/base/java_1.md (100%) rename content/posts/{study => z-study}/java/base/java_10.md (100%) rename content/posts/{study => z-study}/java/base/java_11.md (100%) rename content/posts/{study => z-study}/java/base/java_12.md (100%) rename content/posts/{study => z-study}/java/base/java_13.md (100%) rename content/posts/{study => z-study}/java/base/java_14.md (100%) rename content/posts/{study => z-study}/java/base/java_2.md (100%) rename content/posts/{study => z-study}/java/base/java_3.md (100%) rename content/posts/{study => z-study}/java/base/java_4.md (100%) rename content/posts/{study => z-study}/java/base/java_5.md (100%) rename content/posts/{study => z-study}/java/base/java_6.md (100%) rename content/posts/{study => z-study}/java/base/java_7.md (100%) rename content/posts/{study => z-study}/java/base/java_8.md (100%) rename content/posts/{study => z-study}/java/base/java_9.md (100%) rename content/posts/{study => z-study}/java/mybatis/image-1.png (100%) rename content/posts/{study => z-study}/java/mybatis/image-2.png (100%) rename content/posts/{study => z-study}/java/mybatis/image.png (100%) rename content/posts/{study => z-study}/java/mybatis/mybatis.md (100%) rename content/posts/{study => z-study}/java/mybatis/mybatis_plus.md (100%) rename content/posts/{study => z-study}/java/spring/spring_1.md (100%) rename content/posts/{study => z-study}/lerna.md (100%) rename "content/posts/study/linux\345\237\272\347\241\200.md" => "content/posts/z-study/linux\345\237\272\347\241\200.md" (100%) rename content/posts/{study => z-study}/mysql/JDBC.md (100%) rename content/posts/{study => z-study}/mysql/mysql_1.md (100%) rename content/posts/{study => z-study}/mysql/mysql_2.md (100%) rename content/posts/{study => z-study}/mysql/mysql_3.md (100%) rename "content/posts/study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" => "content/posts/z-study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" (100%) rename "content/posts/study/node/node\345\237\272\347\241\200.md" => "content/posts/z-study/node/node\345\237\272\347\241\200.md" (100%) rename "content/posts/study/node/node\347\232\204\347\211\271\347\202\271.md" => "content/posts/z-study/node/node\347\232\204\347\211\271\347\202\271.md" (100%) rename content/posts/{study => z-study}/node/small_node/index.js (100%) rename content/posts/{study => z-study}/node/small_node/requestHandler.js (100%) rename content/posts/{study => z-study}/node/small_node/route.js (100%) rename content/posts/{study => z-study}/node/small_node/server.js (100%) rename content/posts/{study => z-study}/rollup.md (100%) rename "content/posts/study/shell\345\237\272\347\241\200.md" => "content/posts/z-study/shell\345\237\272\347\241\200.md" (100%) rename "content/posts/study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" => "content/posts/z-study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" (100%) create mode 100644 public/posts/z-study/node/small_node/route.js diff --git a/content/posts/hooks/React_hooks--useContext.md b/content/posts/react/hooks/React_hooks--useContext.md similarity index 100% rename from content/posts/hooks/React_hooks--useContext.md rename to content/posts/react/hooks/React_hooks--useContext.md diff --git a/content/posts/hooks/React_hooks--useEffect&useLayoutEffect.md b/content/posts/react/hooks/React_hooks--useEffect&useLayoutEffect.md similarity index 100% rename from content/posts/hooks/React_hooks--useEffect&useLayoutEffect.md rename to content/posts/react/hooks/React_hooks--useEffect&useLayoutEffect.md diff --git a/content/posts/hooks/React_hooks--useMemo&useCallback.md b/content/posts/react/hooks/React_hooks--useMemo&useCallback.md similarity index 100% rename from content/posts/hooks/React_hooks--useMemo&useCallback.md rename to content/posts/react/hooks/React_hooks--useMemo&useCallback.md diff --git a/content/posts/hooks/React_hooks--useRef.md b/content/posts/react/hooks/React_hooks--useRef.md similarity index 100% rename from content/posts/hooks/React_hooks--useRef.md rename to content/posts/react/hooks/React_hooks--useRef.md diff --git a/content/posts/hooks/React_hooks--useState&useReducer.md b/content/posts/react/hooks/React_hooks--useState&useReducer.md similarity index 100% rename from content/posts/hooks/React_hooks--useState&useReducer.md rename to content/posts/react/hooks/React_hooks--useState&useReducer.md diff --git "a/content/posts/tool/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" "b/content/posts/z-drafts/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" similarity index 67% rename from "content/posts/tool/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" rename to "content/posts/z-drafts/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" index a0cd9c4..90d07f2 100644 --- "a/content/posts/tool/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" +++ "b/content/posts/z-drafts/VsCode\346\240\274\345\274\217\345\214\226\345\273\272\350\256\256.md" @@ -1,9 +1,11 @@ ······················--- -title: 'VsCode格式化建议' +title: 'VsCode 格式化建议' date: 2022-09-18T20:37:14+08:00 tags: [tool, vscode] series: [format] categories: [tool] +draft: true + --- ## 前言 @@ -14,8 +16,8 @@ categories: [tool] 进行配置前,确保安装了以下两个插件: -- ESLint -- Prettier - Code formatter +- ESLint +- Prettier - Code formatter ## 配置 @@ -23,10 +25,10 @@ categories: [tool] ```json { - "editor.formatOnSave": true, // 保存时自动格式化 - "editor.codeActionsOnSave": { - "source.fixAll.eslint": true // 保存时自动修复 - } + "editor.formatOnSave": true, // 保存时自动格式化 + "editor.codeActionsOnSave": { + "source.fixAll.eslint": true // 保存时自动修复 + } } ``` @@ -34,16 +36,16 @@ categories: [tool] ```json { - "printWidth": 80, - "tabWidth": 2, - "useTabs": false, - "semi": false, - "singleQuote": true, - "trailingComma": "none", - "bracketSpacing": true, - "arrowParens": "always", - "htmlWhitespaceSensitivity": "ignore", - "endOfLine": "auto" + "printWidth": 80, + "tabWidth": 2, + "useTabs": false, + "semi": false, + "singleQuote": true, + "trailingComma": "none", + "bracketSpacing": true, + "arrowParens": "always", + "htmlWhitespaceSensitivity": "ignore", + "endOfLine": "auto" } ``` @@ -54,8 +56,8 @@ categories: [tool] 好在社区有了比较好的解决方案: - - `eslint-config-prettier` 让 eslint 忽略与 prettier 产生的冲突 - - `eslint-plugin-prettier` 让 eslint 具有 prettier 格式化的能力 + - `eslint-config-prettier` 让 eslint 忽略与 prettier 产生的冲突 + - `eslint-plugin-prettier` 让 eslint 具有 prettier 格式化的能力 ```sh npm i eslint-config-prettier eslint-plugin-prettier -D @@ -72,21 +74,21 @@ categories: [tool] ```js // node_modules/eslint-plugin-prettier/eslint-plugin-prettier.js module.exports = { - configs: { - recommended: { - extends: ['prettier'], - plugins: ['prettier'], - rules: { - // 让代码文件中不符合prettier格式化规则的都标记为错误, - // 结合vscode-eslint插件便可以看到这些错误被标记为红色, - // 当运行eslint --fix 命令时,将自动修复这些错误。 - 'prettier/prettier': 'error', - 'arrow-body-style': 'off', - 'prefer-arrow-callback': 'off' - } + configs: { + recommended: { + extends: ['prettier'], + plugins: ['prettier'], + rules: { + // 让代码文件中不符合prettier格式化规则的都标记为错误, + // 结合vscode-eslint插件便可以看到这些错误被标记为红色, + // 当运行eslint --fix 命令时,将自动修复这些错误。 + 'prettier/prettier': 'error', + 'arrow-body-style': 'off', + 'prefer-arrow-callback': 'off' + } + } } - } - // ... + // ... } ``` diff --git a/content/posts/study/java/base/java_1.md b/content/posts/z-study/java/base/java_1.md similarity index 100% rename from content/posts/study/java/base/java_1.md rename to content/posts/z-study/java/base/java_1.md diff --git a/content/posts/study/java/base/java_10.md b/content/posts/z-study/java/base/java_10.md similarity index 100% rename from content/posts/study/java/base/java_10.md rename to content/posts/z-study/java/base/java_10.md diff --git a/content/posts/study/java/base/java_11.md b/content/posts/z-study/java/base/java_11.md similarity index 100% rename from content/posts/study/java/base/java_11.md rename to content/posts/z-study/java/base/java_11.md diff --git a/content/posts/study/java/base/java_12.md b/content/posts/z-study/java/base/java_12.md similarity index 100% rename from content/posts/study/java/base/java_12.md rename to content/posts/z-study/java/base/java_12.md diff --git a/content/posts/study/java/base/java_13.md b/content/posts/z-study/java/base/java_13.md similarity index 100% rename from content/posts/study/java/base/java_13.md rename to content/posts/z-study/java/base/java_13.md diff --git a/content/posts/study/java/base/java_14.md b/content/posts/z-study/java/base/java_14.md similarity index 100% rename from content/posts/study/java/base/java_14.md rename to content/posts/z-study/java/base/java_14.md diff --git a/content/posts/study/java/base/java_2.md b/content/posts/z-study/java/base/java_2.md similarity index 100% rename from content/posts/study/java/base/java_2.md rename to content/posts/z-study/java/base/java_2.md diff --git a/content/posts/study/java/base/java_3.md b/content/posts/z-study/java/base/java_3.md similarity index 100% rename from content/posts/study/java/base/java_3.md rename to content/posts/z-study/java/base/java_3.md diff --git a/content/posts/study/java/base/java_4.md b/content/posts/z-study/java/base/java_4.md similarity index 100% rename from content/posts/study/java/base/java_4.md rename to content/posts/z-study/java/base/java_4.md diff --git a/content/posts/study/java/base/java_5.md b/content/posts/z-study/java/base/java_5.md similarity index 100% rename from content/posts/study/java/base/java_5.md rename to content/posts/z-study/java/base/java_5.md diff --git a/content/posts/study/java/base/java_6.md b/content/posts/z-study/java/base/java_6.md similarity index 100% rename from content/posts/study/java/base/java_6.md rename to content/posts/z-study/java/base/java_6.md diff --git a/content/posts/study/java/base/java_7.md b/content/posts/z-study/java/base/java_7.md similarity index 100% rename from content/posts/study/java/base/java_7.md rename to content/posts/z-study/java/base/java_7.md diff --git a/content/posts/study/java/base/java_8.md b/content/posts/z-study/java/base/java_8.md similarity index 100% rename from content/posts/study/java/base/java_8.md rename to content/posts/z-study/java/base/java_8.md diff --git a/content/posts/study/java/base/java_9.md b/content/posts/z-study/java/base/java_9.md similarity index 100% rename from content/posts/study/java/base/java_9.md rename to content/posts/z-study/java/base/java_9.md diff --git a/content/posts/study/java/mybatis/image-1.png b/content/posts/z-study/java/mybatis/image-1.png similarity index 100% rename from content/posts/study/java/mybatis/image-1.png rename to content/posts/z-study/java/mybatis/image-1.png diff --git a/content/posts/study/java/mybatis/image-2.png b/content/posts/z-study/java/mybatis/image-2.png similarity index 100% rename from content/posts/study/java/mybatis/image-2.png rename to content/posts/z-study/java/mybatis/image-2.png diff --git a/content/posts/study/java/mybatis/image.png b/content/posts/z-study/java/mybatis/image.png similarity index 100% rename from content/posts/study/java/mybatis/image.png rename to content/posts/z-study/java/mybatis/image.png diff --git a/content/posts/study/java/mybatis/mybatis.md b/content/posts/z-study/java/mybatis/mybatis.md similarity index 100% rename from content/posts/study/java/mybatis/mybatis.md rename to content/posts/z-study/java/mybatis/mybatis.md diff --git a/content/posts/study/java/mybatis/mybatis_plus.md b/content/posts/z-study/java/mybatis/mybatis_plus.md similarity index 100% rename from content/posts/study/java/mybatis/mybatis_plus.md rename to content/posts/z-study/java/mybatis/mybatis_plus.md diff --git a/content/posts/study/java/spring/spring_1.md b/content/posts/z-study/java/spring/spring_1.md similarity index 100% rename from content/posts/study/java/spring/spring_1.md rename to content/posts/z-study/java/spring/spring_1.md diff --git a/content/posts/study/lerna.md b/content/posts/z-study/lerna.md similarity index 100% rename from content/posts/study/lerna.md rename to content/posts/z-study/lerna.md diff --git "a/content/posts/study/linux\345\237\272\347\241\200.md" "b/content/posts/z-study/linux\345\237\272\347\241\200.md" similarity index 100% rename from "content/posts/study/linux\345\237\272\347\241\200.md" rename to "content/posts/z-study/linux\345\237\272\347\241\200.md" diff --git a/content/posts/study/mysql/JDBC.md b/content/posts/z-study/mysql/JDBC.md similarity index 100% rename from content/posts/study/mysql/JDBC.md rename to content/posts/z-study/mysql/JDBC.md diff --git a/content/posts/study/mysql/mysql_1.md b/content/posts/z-study/mysql/mysql_1.md similarity index 100% rename from content/posts/study/mysql/mysql_1.md rename to content/posts/z-study/mysql/mysql_1.md diff --git a/content/posts/study/mysql/mysql_2.md b/content/posts/z-study/mysql/mysql_2.md similarity index 100% rename from content/posts/study/mysql/mysql_2.md rename to content/posts/z-study/mysql/mysql_2.md diff --git a/content/posts/study/mysql/mysql_3.md b/content/posts/z-study/mysql/mysql_3.md similarity index 100% rename from content/posts/study/mysql/mysql_3.md rename to content/posts/z-study/mysql/mysql_3.md diff --git "a/content/posts/study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" "b/content/posts/z-study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" similarity index 100% rename from "content/posts/study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" rename to "content/posts/z-study/node/koa\346\264\213\350\221\261\346\250\241\345\236\213.md" diff --git "a/content/posts/study/node/node\345\237\272\347\241\200.md" "b/content/posts/z-study/node/node\345\237\272\347\241\200.md" similarity index 100% rename from "content/posts/study/node/node\345\237\272\347\241\200.md" rename to "content/posts/z-study/node/node\345\237\272\347\241\200.md" diff --git "a/content/posts/study/node/node\347\232\204\347\211\271\347\202\271.md" "b/content/posts/z-study/node/node\347\232\204\347\211\271\347\202\271.md" similarity index 100% rename from "content/posts/study/node/node\347\232\204\347\211\271\347\202\271.md" rename to "content/posts/z-study/node/node\347\232\204\347\211\271\347\202\271.md" diff --git a/content/posts/study/node/small_node/index.js b/content/posts/z-study/node/small_node/index.js similarity index 100% rename from content/posts/study/node/small_node/index.js rename to content/posts/z-study/node/small_node/index.js diff --git a/content/posts/study/node/small_node/requestHandler.js b/content/posts/z-study/node/small_node/requestHandler.js similarity index 100% rename from content/posts/study/node/small_node/requestHandler.js rename to content/posts/z-study/node/small_node/requestHandler.js diff --git a/content/posts/study/node/small_node/route.js b/content/posts/z-study/node/small_node/route.js similarity index 100% rename from content/posts/study/node/small_node/route.js rename to content/posts/z-study/node/small_node/route.js diff --git a/content/posts/study/node/small_node/server.js b/content/posts/z-study/node/small_node/server.js similarity index 100% rename from content/posts/study/node/small_node/server.js rename to content/posts/z-study/node/small_node/server.js diff --git a/content/posts/study/rollup.md b/content/posts/z-study/rollup.md similarity index 100% rename from content/posts/study/rollup.md rename to content/posts/z-study/rollup.md diff --git "a/content/posts/study/shell\345\237\272\347\241\200.md" "b/content/posts/z-study/shell\345\237\272\347\241\200.md" similarity index 100% rename from "content/posts/study/shell\345\237\272\347\241\200.md" rename to "content/posts/z-study/shell\345\237\272\347\241\200.md" diff --git "a/content/posts/study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" "b/content/posts/z-study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" similarity index 100% rename from "content/posts/study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" rename to "content/posts/z-study/\345\274\200\345\217\221\344\270\200\344\270\252\345\221\275\344\273\244\350\241\214\345\267\245\345\205\267.md" diff --git a/public/babel/index.html b/public/babel/index.html index bcf1cfa..c0a18df 100644 --- a/public/babel/index.html +++ b/public/babel/index.html @@ -39,7 +39,7 @@ - +