Version 1
[yaffs-website] / node_modules / trim / index.js
diff --git a/node_modules/trim/index.js b/node_modules/trim/index.js
new file mode 100644 (file)
index 0000000..640c24c
--- /dev/null
@@ -0,0 +1,14 @@
+
+exports = module.exports = trim;
+
+function trim(str){
+  return str.replace(/^\s*|\s*$/g, '');
+}
+
+exports.left = function(str){
+  return str.replace(/^\s*/, '');
+};
+
+exports.right = function(str){
+  return str.replace(/\s*$/, '');
+};