scrimba
Imba Changelog
Imba Changelog - Slot Syntax Discussion
Go Pro!Bootcamp

Bootcamp

Study group

Collaborate with peers in your dedicated #study-group channel.

Code reviews

Submit projects for review using the /review command in your #code-reviews channel

Imba Changelog - Slot Syntax Discussion
AboutCommentsNotes
Imba Changelog - Slot Syntax Discussion
Expand for more info
index.imba2
run
preview
console
tag app-panel

def render
<self>
<header>
<slot name='header'> "Item header"
<section.main>
<slot>
<footer>
<slot name='footer'>

tag app-root
def render
<self>
<app-panel>
<div slot='header'>
<h1> "Title for header"

<p> "A paragraph for the main content."
<p> "And another one"

<button slot='footer' :click.refresh> 'Refresh'
<button slot='footer' :click.openInBrowser> 'Open in browser'

Console
/index.html
-23:31