Frontmatter
| id | 7791 |
| title | Refactor ContentComponent to use new highlight.js utilities |
| state | Closed |
| labels | enhancementairefactoring |
| assignees | tobiu |
| createdAt | Nov 18, 2025, 11:13 AM |
| updatedAt | Nov 18, 2025, 8:27 PM |
| githubUrl | https://github.com/neomjs/neo/issues/7791 |
| author | tobiu |
| commentsCount | 0 |
| parentIssue | 7788 |
| subIssues | 7789 Create a utility for highlight.js line numbers 7790 Create a universal ESM bundle for highlight.js |
| subIssuesCompleted | 2 |
| subIssuesTotal | 2 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Nov 18, 2025, 8:27 PM |
Refactor ContentComponent to use new highlight.js utilities
tobiu added sub-issue #7789 on Nov 18, 2025, 11:13 AM
tobiu added sub-issue #7790 on Nov 18, 2025, 11:13 AM
tobiu added parent issue #7788 on Nov 18, 2025, 11:13 AM
tobiu cross-referenced by #7788 on Nov 18, 2025, 11:16 AM
tobiu assigned to @tobiu on Nov 18, 2025, 11:23 AM
tobiu cross-referenced by #7790 on Nov 18, 2025, 1:12 PM
tobiu closed this issue on Nov 18, 2025, 8:27 PM
With the creation of a universal
highlight.jsbundle (#7790) and aHighlightJsLineNumbersutility (#7789), we can now refactorPortal.view.learn.ContentComponentto use this new, unified, and synchronous approach.This will remove the dependency on the main thread addon for highlighting and simplify the component's logic.
Plan
ContentComponent.mjs.Neo.main.addon.HighlightJS.Neo.util.HighlightandNeo.util.HighlightJsLineNumbersutilities.processReadonlyCodeBlocksmethod to be synchronous, using the new utilities to process code blocks.resources/scss/src/util/Highlight.scss.apps/portal/resources/lib/highlightjs-custom-github-theme.cssand the line number styles into this new file.highlightjs-custom-github-theme.css,highlightjs-custom-dark-theme.css). The dark theme can be re-added later if needed, using SCSS variables.