Skip to content

Configuration settings

Andrey Taritsyn edited this page May 27, 2017 · 25 revisions

Since version 1.2.1 Beta from the Web.config file has been removed settings of Bundle Transformer, which were default settings. Current settings of Bundle Transformer equivalent to following version of the Web.config file:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
	<configSections>
		<!-- Declaration of Bundle Transformer configuration section group -->
		<sectionGroup name="bundleTransformer">
			<section name="core"
				type="BundleTransformer.Core.Configuration.CoreSettings, BundleTransformer.Core" />
			<section name="less"
				type="BundleTransformer.Less.Configuration.LessSettings, BundleTransformer.Less" />
			<section name="sassAndScss"
				type="BundleTransformer.SassAndScss.Configuration.SassAndScssSettings, BundleTransformer.SassAndScss" />
			<section name="coffeeScript"
				type="BundleTransformer.CoffeeScript.Configuration.CoffeeScriptSettings, BundleTransformer.CoffeeScript" />
			<section name="typeScript"
				type="BundleTransformer.TypeScript.Configuration.TypeScriptSettings, BundleTransformer.TypeScript" />
			<section name="hogan"
				type="BundleTransformer.Hogan.Configuration.HoganSettings, BundleTransformer.Hogan" />
			<section name="handlebars"
				type="BundleTransformer.Handlebars.Configuration.HandlebarsSettings, BundleTransformer.Handlebars" />
			<section name="autoprefixer"
				type="BundleTransformer.Autoprefixer.Configuration.AutoprefixerSettings, BundleTransformer.Autoprefixer" />
			<section name="microsoftAjax"
				type="BundleTransformer.MicrosoftAjax.Configuration.MicrosoftAjaxSettings, BundleTransformer.MicrosoftAjax" />
			<section name="yui"
				type="BundleTransformer.Yui.Configuration.YuiSettings, BundleTransformer.Yui" />
			<section name="closure"
				type="BundleTransformer.Closure.Configuration.ClosureSettings, BundleTransformer.Closure" />
			<section name="uglify"
				type="BundleTransformer.UglifyJs.Configuration.UglifySettings, BundleTransformer.UglifyJs" />
			<section name="packer"
				type="BundleTransformer.Packer.Configuration.PackerSettings, BundleTransformer.Packer" />
			<section name="csso"
				type="BundleTransformer.Csso.Configuration.CssoSettings, BundleTransformer.Csso" />
			<section name="webGrease"
				type="BundleTransformer.WG.Configuration.WgSettings, BundleTransformer.WG" />
			<section name="clean"
				type="BundleTransformer.CleanCss.Configuration.CleanSettings, BundleTransformer.CleanCss" />
		</sectionGroup>
		<!-- /Declaration of Bundle Transformer configuration section group -->
	</configSections>
	…
	<!-- Bundle Transformer configuration settings -->
	<bundleTransformer xmlns="http://tempuri.org/BundleTransformer.Configuration.xsd">
		<core enableTracing="false"
			jsFilesWithMicrosoftStyleExtensions="MicrosoftAjax.js,MicrosoftMvcAjax.js, MicrosoftMvcValidation.js,knockout-$version$.js">
			<css defaultPostProcessors="UrlRewritingCssPostProcessor"
				defaultMinifier="NullMinifier" usePreMinifiedFiles="true"
				combineFilesBeforeMinification="false">
				<translators>
					<add name="NullTranslator"
						type="BundleTransformer.Core.Translators.NullTranslator, BundleTransformer.Core"
						enabled="false" />
					<add name="LessTranslator"
						type="BundleTransformer.Less.Translators.LessTranslator, BundleTransformer.Less"
						enabled="true" />
					<add name="SassAndScssTranslator"
						type="BundleTransformer.SassAndScss.Translators.SassAndScssTranslator, BundleTransformer.SassAndScss"
						enabled="true" />
				</translators>
				<postProcessors>
					<add name="UrlRewritingCssPostProcessor"
						type="BundleTransformer.Core.PostProcessors.UrlRewritingCssPostProcessor, BundleTransformer.Core"
						useInDebugMode="false" />
					<add name="AutoprefixCssPostProcessor"
						type="BundleTransformer.Autoprefixer.PostProcessors.AutoprefixCssPostProcessor, BundleTransformer.Autoprefixer"
						useInDebugMode="true" />
				</postProcessors>
				<minifiers>
					<add name="NullMinifier"
						type="BundleTransformer.Core.Minifiers.NullMinifier, BundleTransformer.Core" />
					<add name="MicrosoftAjaxCssMinifier"
						type="BundleTransformer.MicrosoftAjax.Minifiers.MicrosoftAjaxCssMinifier, BundleTransformer.MicrosoftAjax" />
					<add name="YuiCssMinifier"
						type="BundleTransformer.Yui.Minifiers.YuiCssMinifier, BundleTransformer.Yui" />
					<add name="KryzhanovskyCssMinifier"
						type="BundleTransformer.Csso.Minifiers.KryzhanovskyCssMinifier, BundleTransformer.Csso" />
					<add name="WgCssMinifier"
						type="BundleTransformer.WG.Minifiers.WgCssMinifier, BundleTransformer.WG" />
					<add name="CleanCssMinifier"
						type="BundleTransformer.CleanCss.Minifiers.CleanCssMinifier, BundleTransformer.CleanCss" />
				</minifiers>
				<fileExtensions>
					<add fileExtension=".css" assetTypeCode="Css" />
					<add fileExtension=".less" assetTypeCode="Less" />
					<add fileExtension=".sass" assetTypeCode="Sass" />
					<add fileExtension=".scss" assetTypeCode="Scss" />
				</fileExtensions>
			</css>
			<js defaultPostProcessors=""
				defaultMinifier="NullMinifier" usePreMinifiedFiles="true"
				combineFilesBeforeMinification="false">
				<translators>
					<add name="NullTranslator"
						type="BundleTransformer.Core.Translators.NullTranslator, BundleTransformer.Core"
						enabled="false" />
					<add name="CoffeeScriptTranslator"
						type="BundleTransformer.CoffeeScript.Translators.CoffeeScriptTranslator, BundleTransformer.CoffeeScript"
						enabled="true" />
					<add name="TypeScriptTranslator"
						type="BundleTransformer.TypeScript.Translators.TypeScriptTranslator, BundleTransformer.TypeScript"
						enabled="true" />
					<add name="HoganTranslator"
						type="BundleTransformer.Hogan.Translators.HoganTranslator, BundleTransformer.Hogan"
						enabled="true" />
					<add name="HandlebarsTranslator"
						type="BundleTransformer.Handlebars.Translators.HandlebarsTranslator, BundleTransformer.Handlebars"
						enabled="true" />
				</translators>
				<minifiers>
					<add name="NullMinifier"
						type="BundleTransformer.Core.Minifiers.NullMinifier, BundleTransformer.Core" />
					<add name="MicrosoftAjaxJsMinifier"
						type="BundleTransformer.MicrosoftAjax.Minifiers.MicrosoftAjaxJsMinifier, BundleTransformer.MicrosoftAjax" />
					<add name="YuiJsMinifier"
						type="BundleTransformer.Yui.Minifiers.YuiJsMinifier, BundleTransformer.Yui" />
					<add name="ClosureRemoteJsMinifier"
						type="BundleTransformer.Closure.Minifiers.ClosureRemoteJsMinifier, BundleTransformer.Closure" />
					<add name="ClosureLocalJsMinifier"
						type="BundleTransformer.Closure.Minifiers.ClosureLocalJsMinifier, BundleTransformer.Closure" />
					<add name="CrockfordJsMinifier"
						type="BundleTransformer.JsMin.Minifiers.CrockfordJsMinifier, BundleTransformer.JsMin" />
					<add name="EdwardsJsMinifier"
						type="BundleTransformer.Packer.Minifiers.EdwardsJsMinifier, BundleTransformer.Packer" />
					<add name="UglifyJsMinifier"
						type="BundleTransformer.UglifyJs.Minifiers.UglifyJsMinifier, BundleTransformer.UglifyJs" />
				</minifiers>
				<fileExtensions>
					<add fileExtension=".js" assetTypeCode="JavaScript" />
					<add fileExtension=".coffee" assetTypeCode="CoffeeScript" />
					<add fileExtension=".litcoffee" assetTypeCode="LiterateCoffeeScript" />
					<add fileExtension=".coffee.md" assetTypeCode="LiterateCoffeeScript" />
					<add fileExtension=".ts" assetTypeCode="TypeScript" />
					<add fileExtension=".mustache" assetTypeCode="Mustache" />
					<add fileExtension=".handlebars" assetTypeCode="Handlebars" />
					<add fileExtension=".hbs" assetTypeCode="Handlebars" />
				</fileExtensions>
			</js>
			<assetHandler disableServerCache="false" serverCacheDurationInMinutes="15"
				disableClientCache="false" />
		</core>
		<less useNativeMinification="false" ieCompat="true"
			strictMath="false" strictUnits="false"
			dumpLineNumbers="None" javascriptEnabled="true"
			globalVariables="" modifyVariables=""
			severity="0">
			<jsEngine name="" />
		</less>
		<sassAndScss useNativeMinification="false" indentType="Space" indentWidth="2"
			lineFeedType="CrLf" precision="5" sourceComments="false" />
		<coffeeScript bare="true">
			<jsEngine name="" />
		</coffeeScript>
		<typeScript allowUnreachableCode="false" allowUnusedLabels="false"
			alwaysStrict="false" downlevelIteration="false"
			forceConsistentCasingInFileNames="false"
			newLine="CrLf" noEmit="false" noEmitHelpers="false"
			noEmitOnError="false" noErrorTruncation="false" noFallthroughCasesInSwitch="false"
			noImplicitAny="false" noImplicitReturns="false" noImplicitThis="false"
			noLib="false" noResolve="false" noUnusedLocals="false" noUnusedParameters="false"
			preserveConstEnums="false" removeComments="false"
			skipDefaultLibCheck="false" skipLibCheck="false"
			strictNullChecks="false" stripInternal="false"
			suppressExcessPropertyErrors="false" suppressImplicitAnyIndexErrors="false"
			suppressTypeCheckingErrors="false"
			target="EcmaScript3" transpileOnly="false">
			<jsEngine name="" />
		</typeScript>
		<hogan useNativeMinification="false"
			variable="templates" namespace="" delimiters="">
			<jsEngine name="" />
		</hogan>
		<handlebars namespace="Handlebars.templates" rootPath=""
			knownHelpers="" knownHelpersOnly="false" data="true">
			<jsEngine name="" />
		</handlebars>
		<autoprefixer cascade="true" add="true" remove="true"
			supports="true" flexbox="true" grid="true" stats="">
			<browsers>
				<add conditionalExpression="> 1%" />
				<add conditionalExpression="last 2 versions" />
				<add conditionalExpression="Firefox ESR" />
			</browsers>
			<jsEngine name="" />
		</autoprefixer>
		<microsoftAjax>
			<css allowEmbeddedAspNetBlocks="false" blocksStartOnSameLine="NewLine"
				ignoreAllErrors="false" ignoreErrorList="" indentSize="4"
				lineBreakThreshold="2147482647" outputMode="SingleLine"
				preprocessorDefineList="" termSemicolons="false"
				colorNames="Hex" commentMode="Important" minifyExpressions="true"
				removeEmptyBlocks="true" severity="0" />
			<js allowEmbeddedAspNetBlocks="false" blocksStartOnSameLine="NewLine"
				ignoreAllErrors="false" ignoreErrorList="" indentSize="4"
				lineBreakThreshold="2147482647" outputMode="SingleLine"
				preprocessorDefineList="" termSemicolons="false"
				alwaysEscapeNonAscii="false" amdSupport="false"
				collapseToLiteral="true" constStatementsMozilla="false"
				debugLookupList="Debug,$Debug,WAssert,Msn.Debug,Web.Debug"
				errorIfNotInlineSafe="false" evalLiteralExpressions="true"
				evalTreatment="Ignore" ignoreConditionalCompilation="false"
				ignorePreprocessorDefines="false" inlineSafeStrings="true"
				knownGlobalNamesList="" localRenaming="CrunchAll"
				macSafariQuirks="true" manualRenamesProperties="true"
				noAutoRenameList="$super" preserveFunctionNames="false"
				preserveImportantComments="true" quoteObjectLiteralProperties="false"
				removeFunctionExpressionNames="true" removeUnneededCode="true"
				renamePairs="" reorderScopeDeclarations="true"
				strictMode="false" stripDebugStatements="true"
				severity="0"/>
		</microsoftAjax>
		<yui>
			<css compressionType="Standard" removeComments="true"
				lineBreakPosition="-1" />
			<js compressionType="Standard" obfuscateJavascript="true"
				preserveAllSemicolons="false" disableOptimizations="false"
				ignoreEval="false" severity="0" lineBreakPosition="-1"
				encoding="UTF8" threadCulture="en-us" />
		</yui>
		<closure>
			<js>
				<remote charset=""
					closureCompilerServiceApiUrl="http://closure-compiler.appspot.com/compile"
					compilationLevel="Simple" excludeDefaultExterns="false"
					language="EcmaScript3" prettyPrint="false"
					useTypesForOptimization="false"
					severity="0" />
				<local acceptConstKeyword="false" allowEs6Output="false" angularPass="false"
					charset="" closureCompilerApplicationPath=""
					compilationLevel="Simple" definitionList=""
					errorList="" exportLocalPropertyDefinitions="false"
					extraAnnotationNameList="" generateExports="false"
					javaVirtualMachinePath=""
					languageInput="EcmaScript3" languageOutput="None"
					prettyPrint="false" processClosurePrimitives="false"
					processJqueryPrimitives="false" singleQuotes="false"
					thirdParty="true" transpileOnly="false"
					turnOffWarningClassList="" useOnlyCustomExterns="false"
					useTypesForOptimization="false" warningList=""
					severity="0" />
			</js>
		</closure>
		<packer>
			<js shrinkVariables="true" base62Encode="false" />
			<jsEngine name="" />
		</packer>
		<uglify>
			<js screwIe8="true" keepFunctionNames="false" severity="0">
				<parsing strict="false" bareReturns="false" />
				<compression compress="true" sequences="true" propertiesDotNotation="true"
					deadCode="true" dropDebugger="true" unsafe="false"
					conditionals="true" comparisons="true" evaluate="true"
					booleans="true" loops="true" unused="true"
					hoistFunctions="true" keepFunctionArgs="true" hoistVars="false"
					ifReturn="true" joinVars="true" collapseVars="false" cascade="true"
					globalDefinitions="" pureGetters="false" pureFunctions=""
					negateIife="true" dropConsole="false"
					angular="false" passes="1" />
				<mangling mangle="true" except="" eval="false"
					topLevel="false" />
				<codeGeneration beautify="false" indentLevel="4" indentStart="0"
					quoteKeys="false" spaceColon="true" asciiOnly="false"
					inlineScript="false" width="80" maxLineLength="32000"
					bracketize="false" semicolons="true"
					comments="some" preserveLine="false"
					unescapeRegexps="false" quoteStyle="Auto"
					keepQuotedProperties="false" wrapIife="false" />
			</js>
			<jsEngine name="" />
		</uglify>
		<csso>
			<css disableRestructuring="false" comments="Exclamation" />
			<jsEngine name="" />
		</csso>
		<webGrease>
			<css shouldMinify="true" ejectCharset="true" />
		</webGrease>
		<clean>
			<css compatibility="*" level="One" severity="0">
				<formatting indentBy="0" indentWith="Space" wrapAt="0">
					<breaksInserting afterAtRule="false" afterBlockBegins="false"
						afterBlockEnds="false" afterComment="false"
						afterProperty="false" afterRuleBegins="false"
						afterRuleEnds="false" beforeBlockEnds="false"
						betweenSelectors="false" />
					<spacesInserting aroundSelectorRelation="false" beforeBlockBegins="false"
						beforeValue="false" />
				</formatting>
				<level1Optimizations cleanupCharsets="true" normalizeUrls="true"
					optimizeBackground="true" optimizeBorderRadius="true"
					optimizeFilter="true" optimizeFont="true"
					optimizeFontWeight="true" optimizeOutline="true"
					removeEmpty="true" removeNegativePaddings="true"
					removeQuotes="true" removeWhitespace="true"
					replaceMultipleZeros="true" replaceTimeUnits="true"
					replaceZeroUnits="true" roundingPrecision="off"
					selectorsSortingMethod="Standard" specialComments="all"
					tidyAtRules="true" tidyBlockScopes="true" tidySelectors="true" />
				<level2Optimizations mergeAdjacentRules="true" mergeIntoShorthands="true"
					mergeMedia="true" mergeNonAdjacentRules="true"
					mergeSemantically="false" overrideProperties="true"
					removeEmpty="true" reduceNonAdjacentRules="true"
					removeDuplicateFontRules="true" removeDuplicateMediaBlocks="true"
					removeDuplicateRules="true" removeUnusedAtRules="false"
					restructureRules="false" skipProperties="" />
			</css>
			<jsEngine name="" />
		</clean>
	</bundleTransformer>
	<!-- /Bundle Transformer configuration settings -->
	…
	<system.webServer>
		…
		<handlers>
			…
			<!-- Declaration of Bundle Transformer HTTP-handlers -->
			<add name="LessAssetHandler" path="*.less" verb="GET"
				type="BundleTransformer.Less.HttpHandlers.LessAssetHandler, BundleTransformer.Less"
				resourceType="File" preCondition="" />
			<add name="SassAssetHandler" path="*.sass" verb="GET"
				type="BundleTransformer.SassAndScss.HttpHandlers.SassAndScssAssetHandler, BundleTransformer.SassAndScss"
				resourceType="File" preCondition="" />
			<add name="ScssAssetHandler" path="*.scss" verb="GET"
				type="BundleTransformer.SassAndScss.HttpHandlers.SassAndScssAssetHandler, BundleTransformer.SassAndScss"
				resourceType="File" preCondition="" />
			<add name="CoffeeScriptAssetHandler" path="*.coffee" verb="GET"
				type="BundleTransformer.CoffeeScript.HttpHandlers.CoffeeScriptAssetHandler, BundleTransformer.CoffeeScript"
				resourceType="File" preCondition="" />
			<add name="LiterateCoffeeScriptAssetHandler" path="*.litcoffee" verb="GET"
				type="BundleTransformer.CoffeeScript.HttpHandlers.CoffeeScriptAssetHandler, BundleTransformer.CoffeeScript"
				resourceType="File" preCondition="" />
			<add name="CoffeeScriptMarkdownAssetHandler" path="*.coffee.md" verb="GET"
				type="BundleTransformer.CoffeeScript.HttpHandlers.CoffeeScriptAssetHandler, BundleTransformer.CoffeeScript"
				resourceType="File" preCondition="" />
			<add name="TypeScriptAssetHandler" path="*.ts" verb="GET"
				type="BundleTransformer.TypeScript.HttpHandlers.TypeScriptAssetHandler, BundleTransformer.TypeScript"
				resourceType="File" preCondition="" />
			<add name="MustacheAssetHandler" path="*.mustache" verb="GET"
				type="BundleTransformer.Hogan.HttpHandlers.HoganAssetHandler, BundleTransformer.Hogan"
				resourceType="File" preCondition="" />
			<add name="HandlebarsAssetHandler" path="*.handlebars" verb="GET"
				type="BundleTransformer.Handlebars.HttpHandlers.HandlebarsAssetHandler, BundleTransformer.Handlebars"
				resourceType="File" preCondition="" />
			<add name="HbsAssetHandler" path="*.hbs" verb="GET"
				type="BundleTransformer.Handlebars.HttpHandlers.HandlebarsAssetHandler, BundleTransformer.Handlebars"
				resourceType="File" preCondition="" />
			<!-- /Declaration of Bundle Transformer HTTP-handlers -->
			…
		</handlers>
		…
	</system.webServer>
</configuration>

If you install the BundleTransformer.ConfigurationIntelliSense package, then while editing a Web.config file will be supported IntelliSense for the bundleTransformer configuration section (implemented by using XML Schema, which is located in the BundleTransformer.Configuration.xsd file:

IntelliSense support when editing the  bundleTransformer configuration section in the Web.config file