♻️ (production flow) use of defineModel
This commit is contained in:
@@ -2,22 +2,15 @@
|
||||
defineProps<{
|
||||
id: string
|
||||
label: string
|
||||
modelValue: string
|
||||
}>()
|
||||
defineEmits<{
|
||||
(event: "update:modelValue", value: string): void
|
||||
}>()
|
||||
|
||||
const modelValue = defineModel<string>()
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="form-input">
|
||||
<label :for="id">{{ label }}</label>
|
||||
<input
|
||||
type="text"
|
||||
id="id"
|
||||
:value="modelValue"
|
||||
@input="$emit('update:modelValue', $event.target?.value ?? '')"
|
||||
/>
|
||||
<input type="text" id="id" v-model="modelValue" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -8,7 +8,7 @@ const newTeam = ref("")
|
||||
|
||||
const addTeam = () => {
|
||||
store.addTeam({
|
||||
name: "User Acceptance Testing",
|
||||
name: newTeam.value,
|
||||
outputs: ["Go for live"],
|
||||
prerequisites: ["new app version is step in staging environment"],
|
||||
intention:
|
||||
|
||||
Reference in New Issue
Block a user