{"action":"closed","issue":{"url":"https://api.github.com/repos/vuejs/vue/issues/1965","labels_url":"https://api.github.com/repos/vuejs/vue/issues/1965/labels{/name}","comments_url":"https://api.github.com/repos/vuejs/vue/issues/1965/comments","events_url":"https://api.github.com/repos/vuejs/vue/issues/1965/events","html_url":"https://github.com/vuejs/vue/issues/1965","id":120436722,"number":1965,"title":"Calling slot not being removed the first time","user":{"login":"pdcmoreira","id":4430606,"avatar_url":"https://avatars.githubusercontent.com/u/4430606?v=3","gravatar_id":"","url":"https://api.github.com/users/pdcmoreira","html_url":"https://github.com/pdcmoreira","followers_url":"https://api.github.com/users/pdcmoreira/followers","following_url":"https://api.github.com/users/pdcmoreira/following{/other_user}","gists_url":"https://api.github.com/users/pdcmoreira/gists{/gist_id}","starred_url":"https://api.github.com/users/pdcmoreira/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pdcmoreira/subscriptions","organizations_url":"https://api.github.com/users/pdcmoreira/orgs","repos_url":"https://api.github.com/users/pdcmoreira/repos","events_url":"https://api.github.com/users/pdcmoreira/events{/privacy}","received_events_url":"https://api.github.com/users/pdcmoreira/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/vuejs/vue/labels/bug","name":"bug","color":"fc2929"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-12-04T16:29:00Z","updated_at":"2015-12-10T00:29:52Z","closed_at":"2015-12-10T00:29:52Z","body":"I'm trying out components with slots and something weird is happening.\r\nMy component is a bootstrap modal, I made it work by passing the boolean prop showEditStateModal which shows or hides the modal. It has a header, body (default) and a footer slot.\r\n\r\nThe problem is, the first time I open the modal after the page load, it correctly copies the slot div to the right place, but also copies it to the default slot (body).\r\nThe dom looks like this:\r\n\r\n```html\r\n<div class=\"modal-content\">\r\n    <div class=\"modal-header undefined\">\r\n        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-hidden=\"true\">×</button>\r\n        <h4 class=\"modal-title\">edit state</h4>\r\n    </div>\r\n    <div class=\"modal-body\">\r\n        <p slot=\"footer\">x</p>\r\n    </div>\r\n    <div class=\"modal-footer\">\r\n        <p slot=\"footer\">x</p>\r\n    </div>\r\n</div>\r\n```\r\n\r\nAfter I close the modal, it correctly copies the element to the footer only. It's only the first time that I open the model that the problem happens.\r\n\r\nAlso, theres another problem, since I'm not giving any content besides the footer slot, the default slot (body), that is in the component's template, should be printed. So I should see \"xyz\" in the body, but it's empty.\r\n\r\nHere are my templates:\r\n\r\nParent:\r\n```html\r\n<modal v-bind:show.sync=\"showEditStateModal\" title=\"edit state\">\r\n    <p slot=\"footer\">x</p>\r\n</modal>\r\n```\r\n\r\nComponent:\r\n```html\r\n<script type=\"x-template\" id=\"modal-template\">\r\n    <div class=\"modal fade\" tabindex=\"-1\" role=\"dialog\"\r\n        v-modal=\"show\"\r\n        v-if=\"show\">\r\n        <div class=\"modal-dialog\">\r\n            <div class=\"modal-content\">\r\n                <div class=\"modal-header {{headerClass}}\">\r\n                    <slot name=\"header\">\r\n                        <button type=\"button\" class=\"close\" data-dismiss=\"modal\" aria-hidden=\"true\">×</button>\r\n                        <h4 class=\"modal-title\" v-if=\"title\" v-text=\"title\"></h4>\r\n                    </slot>\r\n                </div>\r\n                <div class=\"modal-body\">\r\n                    <slot>xyz</slot>\r\n                </div>\r\n                <div class=\"modal-footer\">\r\n                    <slot name=\"footer\"></slot>\r\n                </div>\r\n            </div>\r\n        </div>\r\n    </div>\r\n</script>\r\n```"}}