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

data-turbo-cache deprecated #174

Open
intersecato opened this issue Apr 13, 2024 · 7 comments
Open

data-turbo-cache deprecated #174

intersecato opened this issue Apr 13, 2024 · 7 comments

Comments

@intersecato
Copy link

Getting an error "The [data-turbo-cache=false] selector is deprecated and will be removed in a future version. Use [data-turbo-temporary] instead" when using flasher-toastr.

@yoeunes
Copy link
Member

yoeunes commented Apr 13, 2024

hello @intersecato, thanks for reporting the issue, can you show me the steps to reproduce the issue please ?

@intersecato
Copy link
Author

honestly there isn't much to explain. data-turbo-cache is deprecated and from what I see it is contained within
flasher-toastr/Resources/assets/flasher-toastr.min.js

@yoeunes
Copy link
Member

yoeunes commented Apr 14, 2024

Thank you for the details. I'm releasing v2.0 next week and will include a fix for this issue. For now, you can clear notifications with Turbo using this snippet:

document.addEventListener('turbo:before-cache', () => {
    // 
});

@intersecato
Copy link
Author

Hi @yoeunes
I know it wouldn't be the right repository but I also wanted to point out another deprecation:

User Deprecated: Method "Symfony\Component\HttpKernel\Bundle\Bundle::boot()" might add "void" as a native return type declaration in the future. Do the same in child class "Flasher\Symfony\FlasherSymfonyBundle" now to avoid errors or add an explicit @return annotation to suppress this message.

@yoeunes
Copy link
Member

yoeunes commented Apr 14, 2024

Hi @intersecato,

Thank you for bringing up the Symfony deprecation notice as well. Actually, you're indeed in the right place since the source code is housed in this repository as a monorepo. you can see the updated method here: https://github.com/php-flasher/php-flasher/blob/2.x/src/Symfony/FlasherSymfonyBundle.php#L18

If you have the time, I'd greatly appreciate it if you could review other parts of v2.x branch and let me know if you see any other potential improvements or deprecations. Thanks a lot for your contribution 🙏🏼

@intersecato
Copy link
Author

Hi, I saw the v2.0 release but I see that the repos https://github.com/php-flasher/flasher-symfony and https://github.com/php-flasher/flasher-toastr-symfony are still at version 1.15.14, is this normal?

@yoeunes
Copy link
Member

yoeunes commented May 17, 2024

Hi @intersecato 👋🏼,

Thanks for reaching out! Yes, I've released v2.0.0 across all the related repositories, including https://github.com/php-flasher/flasher-symfony and https://github.com/php-flasher/flasher-toastr-symfony. They should be correctly tagged as v2.0.0. You can also verify this on Packagist at the following links:

Could you please try installing the v2.0.0 and let me know if everything works as expected?

Thanks!

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

No branches or pull requests

2 participants