Files
workspace/code/g3soft-libs/docs/examples/select/basic.vue
T
2026-10-09 17:32:14 +08:00

20 lines
513 B
Vue

<script setup lang="ts">
// 最基础用法:options 默认取 { label, value, disabled }
import { ref } from 'vue'
import { G3Select } from '@g3soft/ui'
const value = ref<number | undefined>(undefined)
const options = [
{ label: '开发环境', value: 1 },
{ label: '测试环境', value: 2 },
{ label: '生产环境', value: 3, disabled: true },
]
</script>
<template>
<div style="width: 240px">
<G3Select v-model="value" :options="options" placeholder="请选择环境" />
</div>
</template>