API Reference
Complete API documentation for components, utilities, and framework core
Select
Dropdown selection control with grid overlay pattern
🔧 Props
| Property | Type | Default | Description |
|---|---|---|---|
| id | string | select-{timestamp} | Unique identifier |
| label | string | undefined | Label text above select |
| options | Array | [] | Options as strings or {value, text} objects |
| value | van.state|string | undefined | Selected value (reactive or primitive) |
| placeholder | string | Select... | Placeholder when no option selected |
| required | boolean | false | Required field indicator |
| onchange | function | undefined | Change event handler |
💻 Examples
Simple Select
javascript•Simple Select
const size = van.state('');
return Select({
label: 'Size',
options: ['Small', 'Medium', 'Large'],
value: size,
onchange: e => size.val = e.target.value
});▶️ Live Preview
💡 Click "Edit Code" to modify the example
🔄 Click "Apply Changes" to see your modifications
↩️ Click "Reset" to restore original code
💡 Usage Tips
🔗 Related
Explore vwf
Discover what vwf can do