JSFiddle - React, Tailwind, and code Playground

by khamer

HTML

<script src="https://unpkg.com/vue@next"></script>
<div id="root">
  <input type="text" v-model="foobar">
  <test-component :name="foobar" />
</div>

JavaScript

const TestComponent = {
	template: `test component name: {{ name }}, stuff: {{ stuff }}`,
	props: ['name'],
	setup (props) {
 		props = Vue.toRefs(props)
  	return {
    	stuff: props.name
    }
  }
}

Vue.createApp({
	components: { TestComponent },
  data: () => ({
  	foobar: 'foobar',
  }),
}).mount('#root');