mirror of
https://github.com/kevin-DL/sapper.git
synced 2026-01-17 13:14:54 +00:00
22 lines
354 B
HTML
22 lines
354 B
HTML
<span>y: {segment} {count}</span>
|
|
<svelte:component this={child.component} {...child.props}/>
|
|
|
|
<span>child segment: {child.segment}</span>
|
|
|
|
<script>
|
|
import counts from '../_counts.js';
|
|
|
|
export default {
|
|
preload() {
|
|
return {
|
|
count: counts.y += 1
|
|
};
|
|
},
|
|
|
|
oncreate() {
|
|
this.set({
|
|
segment: this.get().params.y
|
|
});
|
|
}
|
|
};
|
|
</script> |