You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
381 B
Vue
21 lines
381 B
Vue
<template>
|
|
<el-form :model="form" label-width="auto" style="max-width: 600px">
|
|
<el-form-item label="变量名称">
|
|
<el-input v-model="form.name" />
|
|
</el-form-item>
|
|
</el-form>
|
|
</template>
|
|
|
|
<script lang="ts" setup>
|
|
const form = ref({
|
|
name: ''
|
|
});
|
|
|
|
const onSubmit = () => {
|
|
return `console.log(${form.value.name});\n`;
|
|
};
|
|
|
|
|
|
defineExpose({ onSubmit });
|
|
</script>
|