Skip to content

Commit

Permalink
expose computedContext.registerDependency and ko_subscribable_fun.ini…
Browse files Browse the repository at this point in the history
…t as per issue #2072 to make it easier to write custom observables.
  • Loading branch information
far-blue committed Mar 11, 2017
1 parent a73cee4 commit 99c1cd7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/subscribables/dependencyDetection.js
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,6 @@ ko.computedContext = ko.dependencyDetection = (function () {
ko.exportSymbol('computedContext', ko.computedContext);
ko.exportSymbol('computedContext.getDependenciesCount', ko.computedContext.getDependenciesCount);
ko.exportSymbol('computedContext.isInitial', ko.computedContext.isInitial);
ko.exportSymbol('computedContext.registerDependency', ko.computedContext.registerDependency);

ko.exportSymbol('ignoreDependencies', ko.ignoreDependencies = ko.dependencyDetection.ignore);
1 change: 1 addition & 0 deletions src/subscribables/subscribable.js
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ var ko_subscribable_fn = {
extend: applyExtenders
};

ko.exportProperty(ko_subscribable_fn, 'init', ko_subscribable_fn.init);
ko.exportProperty(ko_subscribable_fn, 'subscribe', ko_subscribable_fn.subscribe);
ko.exportProperty(ko_subscribable_fn, 'extend', ko_subscribable_fn.extend);
ko.exportProperty(ko_subscribable_fn, 'getSubscriptionsCount', ko_subscribable_fn.getSubscriptionsCount);
Expand Down

0 comments on commit 99c1cd7

Please sign in to comment.