Svelte · Junior · Question 27 of 76
What does the style: directive do?
<p style:color={color} style:--columns={columns}>...</p>- ✓Correct answer: Sets an individual inline style or CSS custom property from a value
- 2Imports a stylesheet
- 3Scopes the component's
<style>block
Explanation
Setting a custom property is a clean way to use JavaScript values in the component's CSS.