This is a short article on how to solve a common issue that many newcomers face when they start using Svelte. By default you can't use variables in the style tag, this shows you how to use an action to enable this functionality. Enjoy!
Part two of a three part series on how to use actions in Svelte. To get a basic understanding of actions, checkout the first part.
Today we'll look at how to integrate external libraries in Svelte using actions. We'll also be looking at how to integrate it with Sapper (hint, it's plug and play!).
Ever wondered what all the fuss is about? Actions are a great way to expand the functionality of elements in your markup without having to clutter it up with lots of code.
In this post I will show you what you can do with them; enhance inputs, import external libraries and improve user experience in general.