{"action":"created","issue":{"url":"https://api.github.com/repos/knockout/knockout/issues/1843","labels_url":"https://api.github.com/repos/knockout/knockout/issues/1843/labels{/name}","comments_url":"https://api.github.com/repos/knockout/knockout/issues/1843/comments","events_url":"https://api.github.com/repos/knockout/knockout/issues/1843/events","html_url":"https://github.com/knockout/knockout/issues/1843","id":100474063,"number":1843,"title":"How to bind the registered viewmodel to its corresponding template?","user":{"login":"lzl124631x","id":5824517,"avatar_url":"https://avatars.githubusercontent.com/u/5824517?v=3","gravatar_id":"","url":"https://api.github.com/users/lzl124631x","html_url":"https://github.com/lzl124631x","followers_url":"https://api.github.com/users/lzl124631x/followers","following_url":"https://api.github.com/users/lzl124631x/following{/other_user}","gists_url":"https://api.github.com/users/lzl124631x/gists{/gist_id}","starred_url":"https://api.github.com/users/lzl124631x/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lzl124631x/subscriptions","organizations_url":"https://api.github.com/users/lzl124631x/orgs","repos_url":"https://api.github.com/users/lzl124631x/repos","events_url":"https://api.github.com/users/lzl124631x/events{/privacy}","received_events_url":"https://api.github.com/users/lzl124631x/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-08-12T06:06:14Z","updated_at":"2015-08-12T06:16:57Z","closed_at":null,"body":"I have lots of separate template & viewmodel pairs, each of which stands for a single page. I registered them and want to call `applyBindings` to bind their viewmodel to template respectively, rather than a global ko.applyBindings(). How can I achieve it?\r\n\r\nSome of the template & viewmodel pairs are fetched dynamically via AMD. So a global ko.applyBindings() can't affect those newly fetched templ & vms."},"comment":{"url":"https://api.github.com/repos/knockout/knockout/issues/comments/130183241","html_url":"https://github.com/knockout/knockout/issues/1843#issuecomment-130183241","issue_url":"https://api.github.com/repos/knockout/knockout/issues/1843","id":130183241,"user":{"login":"lzl124631x","id":5824517,"avatar_url":"https://avatars.githubusercontent.com/u/5824517?v=3","gravatar_id":"","url":"https://api.github.com/users/lzl124631x","html_url":"https://github.com/lzl124631x","followers_url":"https://api.github.com/users/lzl124631x/followers","following_url":"https://api.github.com/users/lzl124631x/following{/other_user}","gists_url":"https://api.github.com/users/lzl124631x/gists{/gist_id}","starred_url":"https://api.github.com/users/lzl124631x/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lzl124631x/subscriptions","organizations_url":"https://api.github.com/users/lzl124631x/orgs","repos_url":"https://api.github.com/users/lzl124631x/repos","events_url":"https://api.github.com/users/lzl124631x/events{/privacy}","received_events_url":"https://api.github.com/users/lzl124631x/received_events","type":"User","site_admin":false},"created_at":"2015-08-12T06:16:57Z","updated_at":"2015-08-12T06:16:57Z","body":"Currently I have to call `ko.applyBindings({}, document.getElementById('loading-component'));` to apply the bindings for `<loading id=\"loading-component\"></loading>`. This is trivial."}}