Composing Svelte Components in JavaScript/TypeScript runtime
Let's say we have a Button Component that takes props variant: 'primary'|'secondary' <Button variant='primary' on:click={()=>console.log('hello')}> click </Button> I want to create a PrimaryButton Component that has all props and actions from Button Component but override the props with default values.…