/// <summary>
        /// Transforms the content of the given string.
        /// </summary>
        /// <param name="input">The input string to transform.</param>
        /// <param name="path">The path to the given input string to transform.</param>
        /// <param name="cruncher">The cruncher that is running the transform.</param>
        /// <returns>The transformed string.</returns>
        public string Transform(string input, string path, CruncherBase cruncher)
        {
            // Unfortunately there's no way I know of pulling a list of imports out of
            // Sass so we have to do a manual loop to get the list of file dependencies.
            // This should only happen once though.
            if (cruncher.Options.CacheFiles)
            {
                this.AddImportsToFileMonitors(input, cruncher);
            }

            SassCompiler compiler = new SassCompiler();
            return compiler.CompileSass(input, path);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Transforms the content of the given string.
        /// </summary>
        /// <param name="input">The input string to transform.</param>
        /// <param name="path">The path to the given input string to transform.</param>
        /// <param name="cruncher">The cruncher that is running the transform.</param>
        /// <returns>The transformed string.</returns>
        public string Transform(string input, string path, CruncherBase cruncher)
        {
            // Unfortunately there's no way I know of pulling a list of imports out of
            // Sass so we have to do a manual loop to get the list of file dependencies.
            // This should only happen once though.
            if (cruncher.Options.CacheFiles)
            {
                this.AddImportsToFileMonitors(input, cruncher);
            }

            SassCompiler compiler = new SassCompiler();

            return(compiler.CompileSass(input, path));
        }