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

Support URLs as input parameter #271

Closed
buschtoens opened this issue Feb 7, 2020 · 0 comments · Fixed by #274
Closed

Support URLs as input parameter #271

buschtoens opened this issue Feb 7, 2020 · 0 comments · Fixed by #274

Comments

@buschtoens
Copy link
Owner

buschtoens commented Feb 7, 2020

It would be great, if the {{link}} helper could support URLs that are recognizable by the router.

This would make {{link}} a more usable primitive in scenarios where a "serialized" URL has to be passed, e.g. as a callback query parameter.

{{! origin route }}
<Ui::Button
  @link={{link "signup" query=(hash callback=(get (link "checkout") "url"))}}
>
  Please sign up first to continue
</Ui::Button>
{{! "signup" target route }}
<Ui::Button
  @link={{link fromURL=callback}}
>
  Finish registration
</Ui::Button>
@buschtoens buschtoens changed the title Support URLs as the first parameter Support URLs as input parameter Feb 10, 2020
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

Successfully merging a pull request may close this issue.

1 participant