Your first store in Svelte - create a sign in form! (Rails API backend)

Storing state is common in every application. In Svelte, one of the most common ways to store state is through... stores (imagine that). Stores act as a global variable (more or less) and can be updated, subscribed to (changes) and easily accessed throughout your application, so you don't have to worry about passing them down as props.
⏱️ Timestamps:
  • 00:00 - Introduction
  • 00:25 - Readme
  • 00:45 - layout.svelte
  • 01:00 - Nav.svelte
  • 02:24 - stores.js
  • 02:45 - signin.svelte
  • 05:08 - demo
  • 06:05 - API docs

💌 Newsletter:
  • https://www.programmingtil.com/

🪐Elsewhere:
  • Twitter: https://twitter.com/davidwparker
  • Twitter: https://twitt er.com/programmingtil
  • GitHub: https://github.com/davidwparker

💭Concepts:
  • Stores in Svelte

📚Resources:
  • https://github.com/davidwparker/programmingtil-svelte-sapper/tree/ep7
  • https://svelte.dev/docs#sveltestore

🎬 Subscribe! http://bit.ly/subdavidwparker
My name is David W Parker and I’m creating and publishing videos on ProgrammingTIL to help teach anyone and everyone who wants to code. I’m a huge fan of Ruby on Rails, Svelte, TailwindCSS, and WebGL. I’ve used React a lot in the past, as well as some Vue and AngularJS. I’ve done some professional Python and Django. I like to create real applications and my tutorials will walk you through how to build something real from beginning-to-end.

svelte #sapper

© programmingtil.com