concept file in category svelte

appears as: file, files, files, file
Svelte and Sapper in Action

This is an excerpt from Manning's book Svelte and Sapper in Action.

The REPL error “Failed to construct 'URL': Invalid base URL” typically means that a file created in the REPL is missing its file extension and couldn’t be imported.

To delete a file, click its tab and then click the “X” that appears to the right of the filename.

<script>
  export let age;
  export let ball;
  export let developer;
  export let favoriteColors;
  export let fullName;
  export let onBirthday;
</script>
<div>
  {fullName} is {age} years old and
  {developer ? 'is' : 'is not'} a developer.
</div>
<div>
  They like the colors {favoriteColors.join(' and ')}.
</div>
<div>
  They like to throw {ball.new ? 'a new' : 'an old'} {ball.name}
  that weighs {ball.grams} grams.
</div>
<button on:click={onBirthday}>It's my birthday!</button>
Figure 1.3 Flow of files into and out of the Svelte compiler