资讯专栏INFORMATION COLUMN

前端开发 VS Code 上手使用

Ocean / 2448人阅读

摘要:如果想配置开发工具面向前端及开发人员的配置如果想配置开发工具配置及使用技巧所谓网红编辑器,我觉得比来的更爽,因为的所有操作和插件,对于来说也就是一个插件就能无缝兼容。作为一个前端开发,开箱即用的代码编辑高亮提示都十分友好。

如果想配置 sublime 开发工具 => 面向web前端及node开发人员的vim配置

如果想配置 vim 开发工具 => sublime配置及使用技巧

所谓网红编辑器,我觉得比vim来的更爽,因为vim的所有操作和插件,对于vs code 来说也就是一个插件就能无缝兼容。

比如我之前是一直在使用 sublime 的,使用vs code 之后明显感觉 vscode 无论是配置还是使用都更顺手一点,学习成本很小。当然本文不是谈哪个编辑器更好的问题,每个软件都在发展,相互学习和补充才是重点。

作为一个前端开发,vs code 开箱即用的代码编辑、高亮、提示都十分友好。但作为一个追求完美的程序员,还是装了不少插件,比如

前端开发用的一些插件:

Auto Rename Tag: 当你编辑HTML标签是会自动修改配对标签

HTML Class Suggestions: HTML class 名称提示

ESLint: ES 语法检查

Hap Extension: 快应用开发基础支持

JavaScript(ES6) code snippets: js 代码片段,提高编码速度

open in browser: 在浏览器打开页面,这个已经不常用了,但对于前端初学者还是很友好的

QuickApp For Highlighter: 快应用开发高亮

Color Info: css 中颜色预览

工程化也需要一些插件:

npm: npm 管理

npm Intellisense: npm 自动配置

GitLens: git 记录查看

minify: 代码压缩

写作办公也需要一些工具呀:

Excel Viewer: 实际感觉只能预览 csv 文件,不过这也够用了

Markdown PDF: markdown 转 pdf

Markdown TOC: markdown 目录生成

Markdown+Math: markdown 中数学公式支持

vscode-pdf: pdf 阅读插件

编辑器本身的插件

seti-icons: 文件icon

Theme - Seti-Monokai: 高亮及编辑器外观

Sublime Text Keymap and Settings Importer: sublime 功能键及配置映射

Sublime Babel: sublime

vscode-faker: 随机数据生成

其他的一些工具

SVG Viewer: SVG 图片预览

xtemplate: xtpl 文件高亮支持

我安装了sublime 的插件,其实还有vim 的插件,安装后无缝兼容 .vimrc 配置和 vim plugin。正常的快捷键可以看参考下图,其实和 sublime 差不了太多。

对于一些不如意的地方,可以在配置文件中进行配置,个人感觉 vs code 配置开放比 sublime 更丰富。

{
    "beautify.language": {
        "js": {
            "type": [
                "javascript",
                "json"
            ],
            "filename": [
                ".jshintrc",
                ".jsbeautify"
            ]
        },
        "css": [
            "css",
            "scss",
            "less"
        ],
        "html": [
            "htm",
            "html"
        ]
    },
    "debug.showInStatusBar": "always",
    "debug.node.autoAttach": "off",
    "beautify.tabSize": 2,
    "css.lint.duplicateProperties": "warning",
    "css.lint.idSelector": "warning",
    "css.lint.universalSelector": "warning",
    "css.lint.zeroUnits": "error",
    "less.lint.duplicateProperties": "warning",
    "less.lint.idSelector": "warning",
    "less.lint.universalSelector": "warning",
    "less.lint.zeroUnits": "error",
    "scss.lint.duplicateProperties": "warning",
    "scss.lint.idSelector": "warning",
    "scss.lint.universalSelector": "warning",
    "scss.lint.zeroUnits": "error",
    "csv-preview.skipComments": true,
    "csv-preview.lineNumbers": true,
    "editor.formatOnPaste": true,
    "editor.find.autoFindInSelection": true,
    "editor.formatOnSave": true,
    "editor.fontSize": 14,
    "editor.formatOnType": true,
    "editor.multiCursorModifier": "ctrlCmd",
    "editor.minimap.enabled": false,
    "editor.snippetSuggestions": "top",
    "editor.tabSize": 2,
    "editor.wordSeparators": "`~!@#$%^&*()=+[{]}|;:"",.<>/?",
    "emmet.includeLanguages": {
        "vue-html": "html",
        "javascript": "javascriptreact"
    },
    "emmet.triggerExpansionOnTab": true,
    "emmet.showAbbreviationSuggestions": false,
    "eslint.autoFixOnSave": true,
    "eslint.options": {
        "configFile": "/Users/faremax/eslintrc.json"
    },
    "eslint.run": "onSave",
    "eslint.workingDirectories": [
        "./public",
        "./src"
    ],
    "explorer.confirmDelete": false,
    "explorer.confirmDragAndDrop": false,
    "explorer.openEditors.visible": 4,
    "files.associations": {
        "*.ux": "ux"
    },
    "files.autoSave": "onFocusChange",
    "files.exclude": {
        "**/.git": true,
        "**/.svn": true,
        "**/.hg": true,
        "**/CVS": true,
        "**/.DS_Store": true,
        "**/node_modules": true
    },
    "files.insertFinalNewline": true,
    "files.trimFinalNewlines": true,
    "files.trimTrailingWhitespace": true,
    "git.detectSubmodules": false,
    "gulp.autoDetect": "off",
    "grunt.autoDetect": "off",
    "html.format.wrapLineLength": 0,
    "jake.autoDetect": "off",
    "javascript.implicitProjectConfig.experimentalDecorators": true,
    "markdown-pdf.displayHeaderFooter": false,
    "markdown-pdf.margin.left": "1.8cm",
    "markdown-pdf.margin.right": "1.8cm",
    "markdown-pdf.margin.top": "1cm",
    "markdown.preview.lineHeight": 1.5,
    "markdown.styles": [
        "/Users/faremax/github-markdown.css"
    ],
    "markdown-pdf.styles": [
        "/Users/faremax/github-markdown.css"
    ],
    "markdown-toc.insertAnchor": true,
    "open-in-browser.default": "Google Chrome.app",
    "search.exclude": {
        "**/node_modules": true,
        "**/bower_components": true,
        "**/build": true,
        "**/dist": true,
    },
    "search.location": "sidebar",
    "svgviewer.enableautopreview": true,
    "terminal.explorerKind": "integrated",
    "window.restoreWindows": "all",
    "workbench.statusBar.feedback.visible": false,
    "window.zoomLevel": 0,
    "workbench.colorTheme": "Monokai",
    "workbench.startupEditor": "newUntitledFile"
}

vs code 还有很多实用技巧,可以看官方github: https://github.com/Microsoft/vscode

文章版权归作者所有,未经允许请勿转载,若此文章存在违规行为,您可以联系管理员删除。

转载请注明本文地址:https://www.ucloud.cn/yun/109071.html

相关文章

  • VS Code上手与超实用插件安利

    摘要:软件跨平台支持以及,运行流畅,可谓是微软的良心之作微软有这个宇宙最强,自然也不会弱宇宙最强编辑器说到代码编辑器,我们有必要提一提还有。 原文链接:VS Code上手与超实用插件安利 工欲善其事必先利其器 Visual Studio Code (简称 VS Code / VSC) 是一款免费开源的现代化轻量级代码编辑器,支持几乎所有主流的开发语言的语法高亮、智能代码补全、自定义热键、括号...

    miracledan 评论0 收藏0
  • 黑马前端v7(含Vue3.0小兔鲜儿电商项目)完整代码下载

    摘要:没有过时,它仍然是前端基础的一部分。但无论如何,同时掌握和才是合格的前端同学。。前端综合协议跨域通信安全问题浏览器渲染机制异步和单线程页面性能优化防抖动和节流阀前端错误监控虚拟等。另外,前端常见的有两个和。是的标准,是的超集。 2021已完结​​Download:百度网盘​​提取码:k4H5​前端技术知识汇总:1、HTML...

    senntyou 评论0 收藏0
  • 程序员练级攻略(2018):前端性能优化和框架

    摘要:,谷歌给的一份性能指南和最佳实践。目前而言,前端社区有三大框架和。随后重点讲述了和两大前端框架,给出了大量的文章教程和相关资源列表。我认为,使用函数式编程方式,更加符合后端程序员的思路,而是更符合前端工程师习惯的框架。 showImg(https://segmentfault.com/img/bVbjQAM?w=1142&h=640); 这个是我订阅 陈皓老师在极客上的专栏《左耳听风》...

    VEIGHTZ 评论0 收藏0
  • 程序员练级攻略(2018):前端性能优化和框架

    摘要:,谷歌给的一份性能指南和最佳实践。目前而言,前端社区有三大框架和。随后重点讲述了和两大前端框架,给出了大量的文章教程和相关资源列表。我认为,使用函数式编程方式,更加符合后端程序员的思路,而是更符合前端工程师习惯的框架。 showImg(https://segmentfault.com/img/bVbjQAM?w=1142&h=640); 这个是我订阅 陈皓老师在极客上的专栏《左耳听风》...

    CoffeX 评论0 收藏0

发表评论

0条评论

最新活动
阅读需要支付1元查看
<