Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

com.github.spyrospac:frontend-files-uglifier

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

com.github.spyrospac:frontend-files-uglifier

Maven plugin to minify frontend files.

  • 1.1
  • Source
  • Maven
  • Socket score

Version published
Maintainers
1
Source

frontend-files-uglifier

Welcome! frontend-files-uglifier is a maven plugin to uglify (minify) front end files for Java Web Applications. Currently only JavaScript files can be minified.

Introduction

Frontend files uglifier minifies your project JavaScript files into the same or a different directory, you can add a "min" suffix or replace the existing file. An option is also given to minify only files that are updated later than their minified copies (which are identified by *.min.js). Goal is named uglify.

Parameters

NameTypeDescription
sourcesFileSetThe directory containing javascript source files. (required)
outputDirectoryStringThe output directory to put uglified files. If skipped, the minified file will be created on the same folder.
manglebooleanParameter for mangle (e.g. keep the function parameter names). Default value is true.
keepNamebooleanParameter to minify into a new file with the same name, if set to true. If no output directory is defined, then the existing file will be replaced. Default value is false.
minifyOnlyUpdatedbooleanParameter to minify only js files that are modified after their respective js files. Default value is false.

Example

You can call the plugin during the build process:

<plugin>  
    <groupId>com.github.spyrospac</groupId>  
    <artifactId>frontend-files-uglifier</artifactId>  
    <version>1.0</version>  
  
    <executions>  
        <execution>  
            <id>uglifyjs3</id>  
            <goals>  
                <goal>uglify</goal>  
            </goals>  
            <configuration>  
                <sources>  
                    <directory>web/src/main/webapp/resources/static/jscript</directory>  
                    <excludes>  
                        <exclude>org/foo</exclude>  
                        <exclude>org/bar</exclude>  
                        <exclude>**/*.min.js</exclude>  
                    </excludes>  
                </sources>  
                <minifyOnlyUpdated>true</minifyOnlyUpdated>  
            </configuration>  
        </execution>  
    </executions>  
</plugin>

Acknowledgement

The development of this plugin was done to check on the mojos with TDD. It is based on uglifyjs-maven-plugin, which is not developed anymore. The plugin uses a minified version of the great UglifyJS

FAQs

Package last updated on 30 Jan 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc