033b70a7f8
* Add Component Example * chore(lint): Prettier fix * nit: improve implementation * nit: Update documentation Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
15 lines
No EOL
201 B
Text
15 lines
No EOL
201 B
Text
---
|
|
export interface Props extends Record<any, any> {
|
|
type?: string
|
|
}
|
|
|
|
const {
|
|
type,
|
|
...props
|
|
} = {
|
|
...Astro.props
|
|
} as Props
|
|
|
|
props.type = type || 'button'
|
|
---
|
|
<button {...props}><slot /></button> |