2 个仓库
Components that allow users to define how code blocks are injected into the DOM using custom React components.
Distinct from Custom Code Block Rendering: Focuses on DOM injection and structural customization rather than transforming code into non-textual components like charts.
Explore 2 awesome GitHub repositories matching user interface & experience · Customizable Code Block Renderers. Refine with filters or upvote what's useful.
react-syntax-highlighter 是一个用于在 React 应用程序中渲染带有语法高亮源代码的组件。它充当 PrismJS 和 Highlight.js 引擎的包装器,以提供格式化的代码显示和特定语言的颜色。 该项目提供了一个可定制的代码块渲染器,支持自定义 DOM 注入、行号显示和内联样式。它允许用户用自定义 React 组件替换默认的 HTML 标签,以控制代码如何注入到文档对象模型(DOM)中。 该库通过视觉主题和行号显示来管理代码呈现。它包括用于包优化的机制,例如异步加载高亮引擎和特定语言定义,以减少初始页面加载时间。
Implements a customizable renderer that allows replacing default HTML tags with user-defined React components for granular DOM control.
Braft Editor 是一个基于 Draft.js 的 React 富文本编辑器,为内容创作和格式化提供了一个框架。它作为一个可重用的 UI 组件,允许用户在所见即所得(WYSIWYG)界面中撰写格式化文档,并将结果内容导出为 HTML 字符串。 该项目具有内置的多语言本地化支持,包括中文、日文和韩文。它提供了一个模块化系统,用于通过插件、自定义工具栏映射和专用媒体实体来扩展编辑器功能。 该编辑器涵盖了广泛的内容功能,包括富文本格式化、段落和块样式设置,以及嵌套列表的组织。它支持嵌入多媒体内容,如图像、音频、视频和格式化代码块。文档状态通过受控组件模式进行管理,允许编辑器与应用状态之间的同步。
Includes formatted code blocks that support tab-based indentation and custom visual rendering.