WebStorm front-end development artifact: top ten must-install plug-ins recommended

introduction

WebStorm is a professional JavaScript IDE launched by JetBrains, which provides a powerful JavaScript/TypeScript development environment and workflow. As front-end developers, we can enrich and enhance the functionality of WebStorm by installing various plug-ins. This article will recommend 10 must-install plug-ins for WebStorm front-end development.

1. HTML CSS Support

The HTML CSS Support plug-in provides highlighting, auto-completion, error checking and formatting for HTML and CSS files. It supports HTML5, CSS3 and preprocessors such as LESS and SCSS. After installation, HTML and CSS files will receive the same rich code support as JavaScript.

<!-- HTML代码高亮 -->
<div class="container">
  <p>Hello World</p>
</div>
/* CSS代码高亮 */
.container {
    
    
  color: #333;
}

2. ESLint

The ESLint plug-in can check JavaScript and JSX code for errors, style issues and dangerous operations in real time, and also supports automatic repair. It combines with Webpack to automatically fix issues directly on code save.

// ESLint检查示例
function sum(a, b) {
    
    
 return a + b
}

3. Path Autocomplete

The Path Autocomplete plug-in can automatically complete file paths, which is especially suitable for referencing resource paths such as images and files in front-end projects. Just enter the beginning of the path and it will be automatically completed, greatly improving development efficiency.

// 自动完成图片路径
import logo from './asse../images/logo.png';

4. Prettier

The Prettier plug-in can automatically format code and maintain a unified code style. It is perfectly integrated with ESLint and can format and fix all code problems with one click.

// Prettier格式化前
function foo(bar) {
    
    
  return bar++;
}
// Prettier格式化后 
function foo(bar) {
    
    
  return bar + 1;
}

5. Vue.js

The Vue.js plug-in provides necessary support for Vue project development, such as syntax highlighting, auto-completion, Linting checking, etc. For Vue development, it can be said to be an essential plug-in.

<!-- Vue组件示例 -->
<template>
  <div>{
   
   { message }}</div>
</template>
<script>
export default {
      
      
  data() {
      
      
    return {
      
      
      message: 'Hello Vue!'
    }
  }
}
</script>

6. ReactJS

Similarly, for React projects, the ReactJS plug-in is also a must-install plug-in. It provides JSX syntax support and auto-completion, and can generate React component scaffolding code with one click.

// React组件示例
function HelloMessage({ name }) {
  return <div>Hello {name}!</div>
}

7. JavaScript Debugger

The JavaScript Debugger plug-in can set breakpoints to debug JavaScript code directly in WebStorm. This is very helpful for debugging and problem location.

8. Emmet

The Emmet plug-in supports Zen Coding syntax, which can greatly improve the efficiency of HTML/CSS code writing. Just enter the abbreviation and press Tab to quickly generate a code snippet.

#header>ul>li*3

9. File Watchers

The File Watchers plug-in can monitor file changes and automatically run tasks, such as LESS/Sass compilation, image compression, etc. This is important for front-end development process optimization.

10. GitGraph

The GitGraph plug-in can display Git submission history information and branch merge status in real time, which is very helpful for team collaboration and development.


The above are the 10 must-install plug-ins for WebStorm front-end development that I recommend. They can greatly improve development efficiency. I hope to be helpful!

Guess you like

Origin blog.csdn.net/weixin_46254812/article/details/132418747