做开发的时候,每次import想要代码提示,通过../../src/components长长的相对路径用起来很不方便,通过配置webpack的alias就可以让ide实现代码自动补全功能配置文件内容alias.config.jsconst path = require(‘path’);module.exports = { resolve: { alias: { ‘@’: path.resolve(__dirname, “src”), ‘_c’: path.resolve(__dirname, “src/components”), } }};idea 配置这样就能很愉快的跑起来了