Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Interactivity API: Prevent wrong written directives from killing the runtime #61249

Merged
merged 8 commits into from
May 7, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Move test and add comment
cbravobernal committed May 7, 2024

Verified

This commit was signed with the committer’s verified signature.
commit e7e06a4055c2816d383047693e6fd4d37db1506b
Original file line number Diff line number Diff line change
@@ -6,13 +6,13 @@
*/
?>

<div data-wp-interactive="directive-on">
<?php // A wrong directive name like "data-wp-on--" should not kill the interactivity. ?>
<div data-wp-interactive="directive-on" data-wp-on--="">
<div>
<p data-wp-text="state.counter" data-testid="counter">0</p>
<button
data-testid="button"
data-wp-on--click="actions.clickHandler"
data-wp-on--=""
>Click me!</button>
</div>
<div>