Would it be possible to use lazy builders to add the dynamic parts of the honeypot form, and so allow page caching to function as normal?

Comments

joachim created an issue. See original summary.

geerlingguy’s picture

That's... a good question. I haven't really explored alternative ways to attach the Honeypot fields, but it would be worth exploring in Drupal 8 since caching is a lot more advanced than it was in Drupal 7 (where it was basically "cache everything... or nothing").

If the work to convert things can be done in a way where the current tests (or equivalent alternatives) still pass, I think it would be a background-ish enough task that it wouldn't require a major version bump.

andypost’s picture

It needs work for sure, some forms could use lazy builders (not sure how that could be done for all forms)

claudiu.cristea’s picture

tr’s picture

Version: 8.x-1.x-dev » 2.0.x-dev
Category: Task » Feature request

New features need to be implemented in 2.0.x first at this point.

tr’s picture

Version: 2.0.x-dev » 2.1.x-dev
tr’s picture

Version: 2.1.x-dev » 2.2.x-dev
Status: Active » Postponed

I'm not working on this. If someone wants to implement this idea, feel free to open a MR and set this issue to Active.

joachim’s picture

One caveat is this won't work if BigPipe is enabled, as that loads in Lazy Builder content with JS. Presumably the sort of bots we want to see the honeypot field don't or might not use JS.