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

ajax request using htmx #95

Open
ramiboutas opened this issue Jan 25, 2022 · 1 comment
Open

ajax request using htmx #95

ramiboutas opened this issue Jan 25, 2022 · 1 comment
Labels
question Further information is requested

Comments

@ramiboutas
Copy link

Hi Cory, thank you very much for this repo!

Do you think it is easy to integrate this with htmx? If yes, what files and methods do I have to change or achieve that? Thank you!

@czue
Copy link
Owner

czue commented Jan 26, 2022

You're welcome!

I do think it would be easy to do. You could base most of it off the progress bar example. Then on the backend, instead of returning JSON, you'd just want to return the relevant template fragment.

You could easily copy and modify this view, and then return something like

  <div id='progress-bar' class='progress-bar' style="background-color: #68a9ef; width: {{progress.percent}}%;">&nbsp;</div>

Let me know how it goes!

@czue czue assigned czue and unassigned czue Jan 26, 2022
@czue czue added the question Further information is requested label Jan 26, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants