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

What is the easiest way to make ajax-like call from web page to fiber api #25

Closed
slusarczyk41 opened this issue Jul 6, 2020 · 1 comment

Comments

@slusarczyk41
Copy link

Generaly speaking, I want to retrieve data from a server without reloading a page. I guess I can write a javascript code with something like get('fiber_api_route/get_data') and include it in html template. Is there a better way to do is without a need to write js code? The desired way of doing this is to add to html template something like <button onClick=golang_fiber_function!_name>.
Have a great day
Jacek

@Fenny
Copy link
Member

Fenny commented Jul 20, 2020

Hi @slusarczyk41, you could use HTML5 pushState and render HTML on the server 👍

@Fenny Fenny closed this as completed Jul 31, 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

No branches or pull requests

2 participants