折叠区

webstorm和vscode通用的写法

  1. //#region abc
  2. //#endregion abc
  1. <!--region 弹窗:修改项目详情 -->
  2. <!--endregion 弹窗:修改项目详情 -->

相关eslint配置 https://eslint.org/docs/rules/spaced-comment
允许注释紧跟星号#
'spaced-comment': ['error', 'always', { 'exceptions': ['#'] }]

js类型检查

  1. // @see: https://blog.jetbrains.com/webstorm/2019/09/using-typescript-to-check-your-javascript-code/
  2. // @see: https://www.jetbrains.com/help/webstorm/vue-js.html#ws_vue_linting
  3. // @see: https://code.visualstudio.com/Docs/languages/javascript#_type-checking
  4. {
  5. "compilerOptions": {
  6. "target": "ES6",
  7. "allowJs": true,
  8. "checkJs": true,
  9. "plugins": [
  10. {
  11. "name": "typescript-tslint-plugin"
  12. }
  13. ]
  14. },
  15. "exclude": [
  16. "node_modules"
  17. ]
  18. }