Commits

Matthew Schinckel committed 5547d14

Rename

  • Participants
  • Parent commits 19e6190

Comments (0)

Files changed (2)

File src/knockout.track.js

+(function (root, factory) {
+    if (typeof define === 'function' && define.amd) {
+        // AMD. Register as an anonymous module.
+        define(['knockout'], function (ko) {
+            return factory(ko);
+        });
+    } else {
+        // Browser globals
+        factory(root.ko);
+    }
+}(this, function (ko) {
+
+  ko.subscribable.fn.trackPreviousValue = function() {
+    this.subscribe(function(previousValue) {
+      this.previousValue = previousValue;
+    }, this, 'beforeChange');
+
+    return this;
+  };
+  
+  // We need a custom one for observableArray, as it requires
+  // a slightly different handling.
+  ko.observableArray.fn.trackPreviousValue = function() {
+    this.subscribe(function(previousValue) {
+      this.previousValue = previousValue.slice(0);
+    }, this, 'beforeChange');
+    
+    return this;
+  };
+}));

File src/track.js

-(function (root, factory) {
-    if (typeof define === 'function' && define.amd) {
-        // AMD. Register as an anonymous module.
-        define(['knockout'], function (ko) {
-            return factory(ko);
-        });
-    } else {
-        // Browser globals
-        factory(root.ko);
-    }
-}(this, function (ko) {
-
-  ko.subscribable.fn.trackPreviousValue = function() {
-    this.subscribe(function(previousValue) {
-      this.previousValue = previousValue;
-    }, this, 'beforeChange');
-
-    return this;
-  };
-  
-  // We need a custom one for observableArray, as it requires
-  // a slightly different handling.
-  ko.observableArray.fn.trackPreviousValue = function() {
-    this.subscribe(function(previousValue) {
-      this.previousValue = previousValue.slice(0);
-    }, this, 'beforeChange');
-    
-    return this;
-  };
-}));