Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 | 31 |
Tags
- OpenCV-4.1.0
- xcode
- stackoverflow
- 예제 실행 시 에러 관련_
- OpenCV
- 웹어셈블리 인 액션
- WebAssembly in Action
- homebrew
- VAE
- VisualCapture
- Info.plist
- Camera Usage Description
- mac os
- OpenCV로 배우는 영상처리 및 응용
- pkg-config
- 영상처리
- NSCameraUsageDescription
- AutoEncoder
- Today
- 0
- Total
- 4,360
DEV.log
slot-props 본문
<!-- App.svelte -->
<script>
import Hoverable from './Hoverable.svelte';
</script>
<Hoverable let:hovering={active}>
<div class:active>
{#if active}
<p>I am being hovered upon.</p>
{:else}
<p>Hover over me!</p>
{/if}
</div>
</Hoverable>
<style>
div {
padding: 1em;
margin: 0 0 1em 0;
background-color: #eee;
}
.active {
background-color: #ff3e00;
color: white;
}
</style>
<!-- Hoverable.svelte -->
<script>
let hovering;
function enter() {
hovering = true;
}
function leave() {
hovering = false;
}
</script>
<div on:mouseenter={enter} on:mouseleave={leave}>
<slot hovering={hovering}></slot>
</div>
https://svelte.dev/tutorial/slot-props
Component composition / Slot props • Svelte Tutorial
Component composition / Slot props a. Basicsb. Adding datac. Dynamic attributesd. Stylinge. Nested componentsf. HTML tagsg. Making an appa. Assignmentsb. Declarationsc. Statementsd. Updating arrays and objectsa. Declaring propsb. Default valuesc. Spread pr
svelte.dev
'Svelte > tutorial' 카테고리의 다른 글
sharing-code (0) | 2022.02.01 |
---|---|
context-api (0) | 2022.02.01 |
slot-props (0) | 2022.02.01 |
optional-slots (0) | 2022.02.01 |
named-slots (0) | 2022.02.01 |
slots (0) | 2022.02.01 |
0 Comments