You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Before posting an issue, read the FAQ and search the previous issues.
Description
A clear and concise description of what the bug is, and, unless obvious, what you expected instead.
This is the script in a page.svelte file:
This is the HTML part of the code:
If I change the argument passed as the loading prop to become $loadingStates.login instead of $delayed && $loadingStates.login the login button will accurately depict the state of the loading button once clicked. I am just not sure why the delayed variable is not changing, despite it being said to change in the tutorial/documentation.
I also logged the value of $delayed to the console during the loading of the event button, and it still shows the delayed to be false.
Any guidance would be appreciated.
The text was updated successfully, but these errors were encountered:
There is nothing wrong with $delayed, as you can see from this simple example, so you need to figure out what causes it. Try removing $loadingStates to begin with and see if delayed works as expected at all for you.
I removed $loadingStates and it's still not showing the buttons as loading. Only having the $loadingStates works, but when I add $delayed, it doesn't.
I wrote the below code. It turns out that $delayed always stays false for some reason
$effect: {
console.log("$delayed: ", $delayed);
}
doesn't show the code to update to true at any point. I have tried using update() in the afterSubmit function, and also just using use:enhance as well. none of these work @ciscoheat
Description
A clear and concise description of what the bug is, and, unless obvious, what you expected instead.
This is the script in a page.svelte file:
This is the HTML part of the code:
If I change the argument passed as the loading prop to become $loadingStates.login instead of $delayed && $loadingStates.login the login button will accurately depict the state of the loading button once clicked. I am just not sure why the delayed variable is not changing, despite it being said to change in the tutorial/documentation.
I also logged the value of $delayed to the console during the loading of the event button, and it still shows the delayed to be false.
Any guidance would be appreciated.
The text was updated successfully, but these errors were encountered: