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

ftd.redirect not working with ftd.http response data #1860

Open
siddhantk232 opened this issue May 8, 2024 · 0 comments
Open

ftd.redirect not working with ftd.http response data #1860

siddhantk232 opened this issue May 8, 2024 · 0 comments

Comments

@siddhantk232
Copy link
Contributor

to reproduce:

-- boolean $success: false

-- ftd.redirect: /
if: { success }

-- ftd.text: click me to get response
$on-click$: call-http()


-- void call-http(opts):
ftd.http-options opts: $opts

ftd.http("http://127.0.0.1:3000/test.json", opts)

-- ftd.http-options opts:
redirect: follow
method: POST
fastn-module: www.fifthtry.com/signin

clicking on the rendered text should throw: TypeError: ftd.redirect is not a function (see the browser console)

the response from http://127.0.0.1:3000/test.json is:

{
    "data": {
        "success": true
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant