Skip to content

patchpump/minify-maven-plugin

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Minify Maven Plugin

Minify Maven Plugin combines and minimizes CSS and JavaScript files.

Under the hood, it uses the following compressors:

Usage

Configure your project's pom.xml to run the plugin during the project's build cycle.

<build>
  <plugins>
    <plugin>
      <groupId>patchpump.minify</groupId>
      <artifactId>minify-maven-plugin</artifactId>
      <version>2.8.0-PATCHPUMP-13</version>
      <executions>
        <execution>
          <id>default-minify</id>
          <configuration>
            <charset>UTF-8</charset>
            <cssSourceFiles>
              <cssSourceFile>file-1.css</cssSourceFile>
              <!-- ... -->
              <cssSourceFile>file-n.css</cssSourceFile>
            </cssSourceFiles>
            <jsSourceFiles>
              <jsSourceFile>file-1.js</jsSourceFile>
              <!-- ... -->
              <jsSourceFile>file-n.js</jsSourceFile>
            </jsSourceFiles>
            <jsEngine>CLOSURE</jsEngine>
            <closureWarningLevels>
                <misplacedTypeAnnotation>OFF</misplacedTypeAnnotation>
                <nonStandardJsDocs>OFF</nonStandardJsDocs>
            </closureWarningLevels>
          </configuration>
          <goals>
            <goal>minify</goal>
          </goals>
        </execution>
      </executions>
    </plugin>
  </plugins>
</build>

For more information, check https://github.com/patchpump/minify-maven-plugin

System Requirements

JDK 17

Enable JVMCI (experimental feature)

MAVEN_OPTS=-XX:+UnlockExperimentalVMOptions -XX:+EnableJVMCI -Dpolyglot.engine.WarnInterpreterOnly=false

License

The source code of this distribution is licensed under the terms of the Apache License, Version 2.0.

About

Combine and minimize JavaScript and CSS files for faster page loading.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 100.0%