Skip to content

Change default interface to be the block + function interface - #2

Merged
arunvickram merged 8 commits into
mainfrom
feature/datastar-block
Dec 5, 2025
Merged

arunvickram merged 8 commits into
mainfrom
feature/datastar-block

Conversation

@arunvickram

@arunvickram arunvickram commented Dec 5, 2025 •

Copy link
Copy Markdown
Owner

instead of writing your datastar + cro code like this:

my $response = patch-elements "<div></div>", |%options; 
my $response-2 = patch-signals { a => 2, b => 3 };

content 'text/event-stream', $response ~ $response-2

write it like this:

content 'text/event-stream', datastar {
    patch-elements "<div></div>", |%options;
    patch-signals { a => 2, b => 3 }; 
    remove-elements '#id';
    execute-script '$i += ';
}

@arunvickram
arunvickram merged commit cd4bfe5 into main Dec 5, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant