You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In the following abbreviated components I'd expect to have access to foo in the h1 class attribute. But instead it's only accessible inside the slotted element content.
Parent
<Child{baz}>
Content
<h1slot=foobarlet:fooclass='foobar-{foo.type}'>{foo.title}!</h1><!-- Unexpected behaviour is here - - ^ ^- - - This works fine --></Child>
I'd like the above example to work, with slot let variables in scope at the root slotted element
Alternatives to this include:
Wrapping in a dummy element. (Yuck)
bind:this and manually setting the attributes I want later. (Ulcer inducing)
This is pretty important for slotting tables: if you can't use data from the dataset to add attributes to slotted rows or cells you're missing something pretty darn important...
The text was updated successfully, but these errors were encountered:
In the following abbreviated components I'd expect to have access to
foo
in the h1 class attribute. But instead it's only accessible inside the slotted element content.Parent
Child
I'd like the above example to work, with slot
let
variables in scope at the root slotted elementAlternatives to this include:
bind:this
and manually setting the attributes I want later. (Ulcer inducing)This is pretty important for slotting tables: if you can't use data from the dataset to add attributes to slotted rows or cells you're missing something pretty darn important...
The text was updated successfully, but these errors were encountered: