`

js压缩打包

    博客分类:
  • java
 
阅读更多

<!-- js压缩 -->
            <plugin>
                <groupId>net.alchim31.maven</groupId>
                <artifactId>yuicompressor-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <id>compress</id>
                        <phase>process-resources</phase>
                        <goals>
                            <goal>compress</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <encoding>UTF-8</encoding>
                    <nosuffix>true</nosuffix>
                    <jswarn>false</jswarn>
                    <linebreakpos>-1</linebreakpos>
                    <excludes>
                        <exclude>**/*.min.js</exclude>
                        <exclude>**/*-min.js</exclude>
                    </excludes>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <configuration>
                    <warSourceExcludes>**/js/**,**/css/**</warSourceExcludes>
                </configuration>
            </plugin>

分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics