浏览代码

use String#trim() to fix issues with IE

Kyle P Davis 10 年之前
父节点
当前提交
8e2132fd0b
共有 1 个文件被更改,包括 2 次插入2 次删除
  1. 2 2
      index.js

+ 2 - 2
index.js

@@ -100,7 +100,7 @@ function($scope, $timeout, $interpolate) {
 			throw new Error("invalid exampleName");
 			throw new Error("invalid exampleName");
 		var example = $scope.examples[$scope.exampleName];
 		var example = $scope.examples[$scope.exampleName];
 
 
-		$scope.inputs = "exports.inputs = " + getFormattedDocs(example.inputs).trimRight() + ";\n";
+		$scope.inputs = "exports.inputs = " + getFormattedDocs(example.inputs).trim() + ";\n";
 
 
 		$scope.pipeline = "exports.pipeline = [\n" +
 		$scope.pipeline = "exports.pipeline = [\n" +
 			"\n\t" +
 			"\n\t" +
@@ -139,7 +139,7 @@ function($scope, $timeout, $interpolate) {
 
 
 				var output = aggregate(pipeline, inputs);
 				var output = aggregate(pipeline, inputs);
 
 
-				$scope.output = "exports.outputs = " + getFormattedDocs(output).trimRight() + ";\n";
+				$scope.output = "exports.outputs = " + getFormattedDocs(output).trim() + ";\n";
 
 
 				$scope.isRunning = false;
 				$scope.isRunning = false;