Last active
March 27, 2017 18:39
-
-
Save DavidStrada/2698d99f74d362fccd2b22d9f901ad22 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fields: | |
test_addon: | |
type: test | |
validate: required |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Child = { | |
template: '<div>A custom component! that can include other childs</div>' | |
} | |
Vue.component('test-fieldtype', { | |
template: `<div> | |
Testing addon | |
<my-component></my-component> | |
</div>`, | |
props: ['data', 'config', 'name'], | |
data: function() { | |
return { | |
// | |
}; | |
}, | |
components: { | |
'my-component': Child | |
}, | |
computed: { | |
// | |
}, | |
methods: { | |
// | |
}, | |
ready: function() { | |
// | |
} | |
}); | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Child = { | |
template: '<div>A custom component! that can include other childs</div>' | |
} | |
var Child2 = { | |
template: `<div>I'm a new child :)</div>` | |
} | |
Vue.component('test-fieldtype', { | |
template: `<div> | |
Testing addon | |
<my-component></my-component> | |
<my-component2></my-component2> | |
</div>`, | |
props: ['data', 'config', 'name'], | |
data: function() { | |
return { | |
// | |
}; | |
}, | |
components: { | |
'my-component': Child, | |
'my-component2': Child2 | |
}, | |
computed: { | |
// | |
}, | |
methods: { | |
// | |
}, | |
ready: function() { | |
// | |
} | |
}); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment