public SourceMapGenerator(string scriptPath, string sourceRoot, string basePath, UnicodeNewline?forceEols = null) { string scriptFileName = Path.GetFileName(scriptPath); this.SourceMapBuilder = new SourceMapBuilder(scriptFileName, sourceRoot, basePath); this.ForceEols = forceEols; }
private void PrintStringListOn(List <string> strings, StringBuilder buffer) { bool first = true; buffer.Append("["); foreach (string str in strings) { if (!first) { buffer.Append(","); } buffer.Append(SourceMapBuilder.EscapeQuotedStringLiteral(str, true)); first = false; } buffer.Append("]"); }
private void PrintStringListOn(List <string> strings, bool isPath, StringBuilder buffer) { bool first = true; buffer.Append("["); foreach (string str in strings) { if (!first) { buffer.Append(","); } buffer.Append(SourceMapBuilder.EscapeQuotedStringLiteral(isPath ? GetRelativePath(str, this._basePath) : str, true)); first = false; } buffer.Append("]"); }