Skip to main content
Create new
Introduction
Reactivity
Props
Logic
Events
Bindings
Lifecycle
Stores
Motion
Transitions
Animations
Easing
SVG
Actions
Classes
Component composition
Context API
Special elements
Module context
Debugging
7GUIs
Miscellaneous
App.svelte
Props.svelte
Props2.svelte
Ticker.svelte
<script>
import Ticker from './Ticker.svelte';
import Props from './Props2.svelte';
let props = {
direction: ['left', [ 'left', 'right', 'top', 'bottom' ]],
duration: 30,
delay: 0,
loop: true,
pausing: true,
alternate: false,
behavior: ['auto', [ 'auto', 'always' ]]
};
</script>

<Props
{...props}
let:props
>
<div>
<Ticker {...props}>
<p>Neque porro quisquam est qui dolorem ipsum quia dolor...</p>
</Ticker>
</div>
</Props>

<style>
div {
background: lightgray;
width: 50%;
max-height: 50px;
overflow: hidden;
padding: 10px;
margin: 10px;
}
</style>
loading Svelte compiler...
/* Select a component to see its compiled code */
result = svelte.compile(source, {
generate: ,
});
/* Select a component to see its compiled code */