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

Bump leptos from 0.5.2 to 0.5.3 #54

Merged
merged 2 commits into from
Nov 28, 2023
Merged

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Nov 28, 2023

Bumps leptos from 0.5.2 to 0.5.3.

Release notes

Sourced from leptos's releases.

v0.5.3

v0.5.3

Along with the usual set of bugfixes and small improvements, there are two noteworthy additions in this release.

Improved rust-analyzer support in #[component] macro body

Good LSP support for proc macros is hard, because proc macros depend on parsing a stream of input into a valid Rust syntax tree, but while typing you are constantly creating a stream of new, invalid trees. This release tweaks how the #[component] macro emits code in order to enable better rust-analyzer support within the body of components.

If you've disabled rust-analyzer inside #[component] for better DX, try toggling that off and see if this is a better experience than it was before!

Apologies for any regressions this causes. Please report any issues that arise.

There is still additional work to be done to support rust-analyzer in the view! macro. The hoped-for improvements here are solely inside the #[component] body.

Optional Context <Provider/> Component

Since 0.5.0, there've been a couple instances of bugs or confusing behavior related to the fact that context now follows the reactive graph, not the component tree (see #1986, #2038).

This release includes a <Provider/> component that provides a certain value via context only to its children:

#[component]
pub fn App() -> impl IntoView {
    // each Provider will only provide the value to its children
    view! {
        <Provider value=1u8>
            // correctly gets 1 from context
            {use_context::<u8>().unwrap_or(0)}
        </Provider>
        <Provider value=2u8>
            // correctly gets 2 from context
            {use_context::<u8>().unwrap_or(0)}
        </Provider>
        // does not find any u8 in context
        {use_context::<u8>().unwrap_or(0)}
    }
}

provide_context continues working as it has since 0.5.0, and if you're using it without problems you can ignore this, or use it if you prefer to aesthetics. If you're in a situation where you need to provide multiple context values of the same type and ensure that they are scoped correctly and that siblings do not overwrite one another, use <Provider/>. If you have no idea what I mean, check the issues above for examples of the bugs this fixes.

Complete Changelog

... (truncated)

Commits
  • d6ee2a3 v0.5.3
  • 18a92bb fix: improved rust-analyzer support in #[component] macro (#2075)
  • 4e8c3ac fix: make prop serialization opt-in for devtools (closes #1952) (#2081)
  • a8e25af ci(leptos): run ci on change instead of check (#2061)
  • d531848 fix: dispose previous route or outlet before rendering new one (closes #2070)...
  • 670f415 docs: add instruction to install trunk to examples/README.md (#2064)
  • 061213c fix: correctly mark Trigger as clean when it is re-tracked (closes #1948, #...
  • 0ce4ee8 docs: add warning for nested Fn in attribute (see #2023) (#2045)
  • 1cd6603 ci(examples): fix portal test (#2051)
  • 453911e examples: updated axum session to latest 0.9 in examples (#2049)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file rust Pull requests that update Rust code labels Nov 28, 2023
Bumps [leptos](https://github.com/leptos-rs/leptos) from 0.5.2 to 0.5.3.
- [Release notes](https://github.com/leptos-rs/leptos/releases)
- [Commits](leptos-rs/leptos@v0.5.2...v0.5.3)

---
updated-dependencies:
- dependency-name: leptos
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <[email protected]>
@dependabot dependabot bot force-pushed the dependabot/cargo/leptos-0.5.3 branch from e01024f to 4a86047 Compare November 28, 2023 13:37
@shamilsan shamilsan merged commit a90a636 into master Nov 28, 2023
2 checks passed
@shamilsan shamilsan deleted the dependabot/cargo/leptos-0.5.3 branch November 28, 2023 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file rust Pull requests that update Rust code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant