To start off our Todo application, let's go ahead and utilize the template that we already have. Now, in most Todo applications, we want to be able to do the following things:
- Add
- Remove/mark complete
- Update
So what we have is a basic CRUD application without any server operations. Let's go ahead and write the Svelte HTML that we would expect for this application:
<script>
import { createEventDispatcher } from 'svelte';
export let completed;
export let num;
export let description;
const dispatch = createEventDispatcher();
</script>
<style>
.completed {
text-decoration: line-through;
}
</style>
<li class:completed>
Task {num}: {description}
<input type="checkbox" bind:checked={completed} />
<button on:click="{() => dispatch...