Created
July 3, 2012 22:38
-
-
Save pk11/3043883 to your computer and use it in GitHub Desktop.
using WHITESPACE only compilation level and pretty printing for an alternative closure CompilerOptions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//in Build.scala | |
//requires play 2.1! | |
import com.google.javascript.jscomp._ | |
val defaultOptions = new CompilerOptions() | |
defaultOptions.closurePass = true | |
CompilationLevel.WHITESPACE_ONLY.setOptionsForCompilationLevel(defaultOptions) | |
defaultOptions.setProcessCommonJSModules(true) | |
val root = new java.io.File(".") | |
defaultOptions.setCommonJSModulePathPrefix(root.getCanonicalPath+"/app/assets/javascript/") | |
defaultOptions.setPrettyPrint(true) | |
val main = PlayProject(appName, appVersion, appDependencies, mainLang = SCALA).settings( | |
closureCompilerSettings(defaultOptions):_* | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment