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

Close if empty html #124

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

elalemanyo
Copy link

@elalemanyo elalemanyo commented Nov 16, 2022

I think it makes more sense to open the results only when there are results. In my case, this resulted in some style inconsistencies.

shot2022-11-16 at 16 37 59@2x

@netlify
Copy link

netlify bot commented Nov 16, 2022

Deploy Preview for stimulus-autocomplete ready!

Name Link
🔨 Latest commit b3e3f3d
🔍 Latest deploy log https://app.netlify.com/sites/stimulus-autocomplete/deploys/63eaa6f44d08750008fcd686
😎 Deploy Preview https://deploy-preview-124--stimulus-autocomplete.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

@elalemanyo
Copy link
Author

@ACPK
Copy link

ACPK commented Mar 1, 2023

@elalemanyo Yes but the Rails example should be updated to reflect the change.

I found that HTML (from this PR) returns true due to a code comment with the name of the controller.

Doesn't work: render layout: false if [email protected]?

It could be resolved in Rails 7 by adding the following code to the controller.

Works: head 200, content_type: "text/html" if [email protected]?

@elalemanyo
Copy link
Author

@afcapel Is there any possibility to merge this? We believe it could be of interest to other users.
Thanks

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 this pull request may close these issues.

2 participants