-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add before-highlightall hook #890
Conversation
Needed for unescaped markup plugin, as discussed in #887. Alternatively, we could reinstate @zeitgeist87’s PR about making the selector a config option. Thoughts?
If we're getting a |
For parity or because there are use cases? |
A place to resolve a promise was what I was thinking originally, though in retrospect, it wouldn't actually handle what I was trying to do at the time, which was resolve a promise when all the async highlighting was finished. I ended up not going that route, so maybe it's not necessary, but I thought it might still be useful to include. |
The hook var elements = env.elements || document.querySelectorAll(env.selector); This would optionally enable a plugin to select/filter the elements directly. Could be useful in the future... |
I like that idea! |
* gh-pages: (22 commits) Remove direction-property from themes Add tests for new greedy-pattern feature and fix bug in Kotlin Fix double HTML-encoding bug in Groovy language Add comments to better document the greedy-pattern feature Partial solution for the "Comment-like substrings"-problem Add property 'aliasTitles' to components.js [unescaped markup] Fix small issues @zeitgeist87 pointed out [unescaped markup] Fixed bug with escaped </script> Added unescaped markup plugin (hidden) Implemented @zeitgeist87’s suggestion in PrismJS#890 re: env.elements Changed weight in the header, as we’re now 2KB minified & gzipped. Also way overdue :) Changed the text in the header. Way overdue, as Prism’s popularity has way surpassed that of Dabblet Add before-highlightall hook Fix catastrophic backtracking regex issues Add missing prism.js to the documentation of normalize-whitespace Cleanup normalize-whitespace and improve keep-markup integration Preserve Markup in Normalize-Whitespace plugin Update CHANGELOG and run gulp Removed firstWhiteSpaces code Add support for automatic line breaks ... # Conflicts: # components.js
Needed for unescaped markup plugin, as discussed in #887.
Alternatively, we could reinstate @zeitgeist87’s PR about making the selector a config option.
Thoughts?