IDEA(pycharm,phpstorm)添加外部插件-yuicompressor压缩js/css步骤:
1.下载yuicompressor.jar https://pan.baidu.com/s/1viwqSjhxRRn3qvUPfdrFow
2.选择File->Settings:
image.png
3.选择Tools—>External Tools,点击右侧的“+”:
image.png
4.填写信息
image.png
image.png
5.选中js文件,右键,选择External Tools—>js compress:
image.png
6、最后效果:
image.png
arguments 参数填写示例:
-jar "D:\Program Files\JetBrains\PyCharm 2019.2.3\yuicompressor.jar" --type js --charset utf-8 $FilePath$ -o $FileNameWithoutExtension$.min.js
-jar "D:\Program Files\JetBrains\PyCharm 2019.2.3\yuicompressor.jar" --type css --charset utf-8 $FilePath$ -o $FileNameWithoutExtension$.min.css
网友评论