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

Introduce doNotParse callback setting to allow for implimenters to bypass notes. #129

Open
peterwilsoncc opened this issue Mar 9, 2025 · 0 comments

Comments

@peterwilsoncc
Copy link

The WordPress version of Twemoji has been modified to introduce a doNotParse callback to be included in the settings to indicate that a node should not be parsed.

For WordPress, contributors use this to bypass any node that includes the class wp-exclude-emoji. For context, see the WordPress ticket #52219.

Would it be possible to introduce the use of the custom callback to Twemoji Core?

For WordPress, we make use of the callback in parse() and grabAllTextNodes() but I am happy to provide a PR if you are willing to consider the setting as suitable for the Twemoji library.

@peterwilsoncc peterwilsoncc changed the title Introduce twemoji.doNotParse callback to allow for implimenters to bypass notes. Introduce doNotParse callback setting to allow for implimenters to bypass notes. Mar 9, 2025
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

1 participant