Skip to content

Conversation

@marcoroth
Copy link
Owner

@marcoroth marcoroth commented Oct 22, 2025

This pull request updates the Herb::Engine to accept new attrfunc, jsfunc, and cssfunc options.

This enables ReActionView (and Rails) to customize these escape functions (similar to how it's already customizing escapefunc) so that we can avoid the double escaping.

Since ActionView uses ActionView::OutputBuffer instead of String it would end up be double-escaped if we didn't allow it to be customized and set to "" (see marcoroth/reactionview#12).

Enables marcoroth/reactionview#53

@marcoroth marcoroth added feature New feature or request engine labels Oct 22, 2025
@marcoroth marcoroth force-pushed the engine-customizable-escape-functions branch from c3021ab to c1ad7a4 Compare October 22, 2025 20:22
@marcoroth marcoroth changed the title Engine: Add support for customizing the escape functions Engine: Add support for customizing escape functions Oct 22, 2025
@marcoroth marcoroth marked this pull request as ready for review October 22, 2025 20:55
@marcoroth marcoroth merged commit b8a4b16 into main Oct 22, 2025
20 checks passed
@marcoroth marcoroth deleted the engine-customizable-escape-functions branch October 22, 2025 20:56
@marcoroth marcoroth added the ruby label Oct 22, 2025
marcoroth added a commit to marcoroth/reactionview that referenced this pull request Dec 4, 2025
Depends on marcoroth/herb#720
Resolves #12

---------

Co-authored-by: Koji NAKAMURA <kozy4324@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

engine feature New feature or request ruby

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants