<div id="app" class="m-3">
<small-form url="#">
<div class="col-auto">
<input type="text" class="form-control">
</div>
</small-form>
</div>
Vue.component("x-button", {
props: ['text'],
template: `
<button class="btn btn-primary">
{{ text }}
</button>
`
});
Vue.component("small-form", {
props: ['url'],
template: `
<form action="url" method="post">
<div class="form-row align-items-center">
<slot></slot>
<x-button text="Submit"></x-button>
</div>
</form>
`
});
var vue = new Vue({
el: "#app"
});