Skip to content

Conversation

its-the-shrimp
Copy link
Contributor

Description

Fixes #3478 and changes DynamicName::expr's type to not redundantly parse the expression in the brackets and to not trigger an unused_braces warning with the generated code

Checklist

  • I have reviewed my own code
  • I have added tests

@github-actions
Copy link

github-actions bot commented Oct 28, 2023

Visit the preview URL for this PR (updated for commit 3d983e5):

https://yew-rs-api--pr3497-remove-old-class-syn-fk69c597.web.app

(expires Sat, 04 Nov 2023 13:20:53 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

@github-actions
Copy link

github-actions bot commented Oct 28, 2023

Benchmark - SSR

Yew Master

Benchmark Round Min (ms) Max (ms) Mean (ms) Standard Deviation
Baseline 10 384.106 386.633 384.414 0.781
Hello World 10 673.358 678.270 676.808 1.467
Function Router 10 2143.022 2171.322 2153.170 7.923
Concurrent Task 10 1006.380 1008.670 1007.418 0.693
Many Providers 10 1536.662 1583.896 1550.130 16.171

Pull Request

Benchmark Round Min (ms) Max (ms) Mean (ms) Standard Deviation
Baseline 10 384.080 386.651 384.374 0.801
Hello World 10 669.885 675.609 672.042 2.509
Function Router 10 2157.907 2171.673 2165.224 4.285
Concurrent Task 10 1006.671 1007.578 1007.373 0.259
Many Providers 10 1528.054 1587.171 1543.211 20.324

@github-actions
Copy link

github-actions bot commented Oct 28, 2023

Size Comparison

examples master (KB) pull request (KB) diff (KB) diff (%)
async_clock 103.360 103.360 0 0.000%
boids 176.817 176.817 0 0.000%
communication_child_to_parent 95.831 95.831 0 0.000%
communication_grandchild_with_grandparent 109.030 109.030 0 0.000%
communication_grandparent_to_grandchild 105.435 105.435 0 0.000%
communication_parent_to_child 93.314 93.314 0 0.000%
contexts 112.714 112.714 0 0.000%
counter 90.002 90.002 0 0.000%
counter_functional 90.663 90.663 0 0.000%
dyn_create_destroy_apps 93.225 93.225 0 0.000%
file_upload 104.261 104.261 0 0.000%
function_memory_game 175.886 175.886 0 0.000%
function_router 353.806 353.806 0 0.000%
function_todomvc 164.230 164.230 0 0.000%
futures 232.174 232.174 0 0.000%
game_of_life 113.148 113.148 0 0.000%
immutable 190.273 190.273 0 0.000%
inner_html 86.320 86.320 0 0.000%
js_callback 113.781 113.781 0 0.000%
keyed_list 202.673 202.673 0 0.000%
mount_point 89.213 89.213 0 0.000%
nested_list 117.399 117.399 0 0.000%
node_refs 96.923 96.923 0 0.000%
password_strength 1753.925 1753.925 0 0.000%
portals 98.070 98.070 0 0.000%
router 322.340 322.340 0 0.000%
simple_ssr 144.692 144.692 0 0.000%
ssr_router 391.806 391.806 0 0.000%
suspense 120.140 120.140 0 0.000%
timer 92.549 92.549 0 0.000%
timer_functional 101.335 101.335 0 0.000%
todomvc 144.317 144.317 0 0.000%
two_apps 90.062 90.062 0 0.000%
web_worker_fib 138.945 138.945 0 0.000%
web_worker_prime 189.679 189.679 0 0.000%
webgl 88.930 88.930 0 0.000%

✅ None of the examples has changed their size significantly.

@github-actions
Copy link

Benchmark - core

Yew Master

vnode           fastest       │ slowest       │ median        │ mean          │ samples │ iters
╰─ vnode_clone  5.73 ns       │ 5.957 ns      │ 5.889 ns      │ 5.881 ns      │ 100     │ 1000000000

Pull Request

vnode           fastest       │ slowest       │ median        │ mean          │ samples │ iters
╰─ vnode_clone  5.701 ns      │ 6.838 ns      │ 5.889 ns      │ 5.891 ns      │ 100     │ 1000000000

Copy link
Member

@ranile ranile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me

@ranile ranile requested review from cecton and futursolo October 28, 2023 14:41
@ranile ranile added breaking change A-yew-macro Area: The yew-macro crate labels Oct 28, 2023
@ranile ranile enabled auto-merge (squash) October 28, 2023 14:42
@ranile ranile merged commit bae0141 into yewstack:master Oct 28, 2023
geoffjay pushed a commit to geoffjay/yew that referenced this pull request Jan 25, 2025
* removed class=(...) syntax

* made DynamicName::expr a group instead of a block

* fixed tests, silenced all unused_must_use warnings

* fixed wasm test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-yew-macro Area: The yew-macro crate breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecated feature that should have been removed 2 versions ago
3 participants