4 个仓库
Template systems specifically designed for the Ruby ecosystem to generate markup using embedded logic.
Distinct from Ruby Frameworks: None of the candidates describe a general-purpose Ruby template engine; they focus on execution runtimes, linters, or web frameworks.
Explore 4 awesome GitHub repositories matching web development · Ruby Template Engines. Refine with filters or upvote what's useful.
Slim 是一种简洁的、基于缩进的模板语言和标记引擎,用于生成 HTML 和 XML。它专为 Ruby 生态系统设计,将简写语法转换为格式良好的文档,无需传统的闭合标签。 该引擎作为一个多引擎封装器,允许在单个模板文件中集成 Markdown 和 Sass 等外部渲染引擎。它还提供了一个用于渲染模板并在不同标记格式之间进行转换的命令行接口。 该系统通过嵌入式 Ruby 逻辑支持动态内容生成,包括循环、条件判断和表达式插值。它包括用于通过可重用模板片段进行模块化 UI 开发的功能,以及用于空白管理、文档类型生成和将数据集合映射到元素属性的专门工具。
Provides a concise, Ruby-compatible template engine for generating HTML and XML markup.
Opal 是一个 Ruby 前端框架和编译器,将 Ruby 源代码转换为 JavaScript。它作为一个 Web 运行时,允许使用 Ruby 而不是 JavaScript 开发客户端 Web 应用。 该项目包含一个直接在标记文件中评估嵌入式 Ruby 代码的 Ruby HTML 模板引擎。它进一步通过将核心库和依赖项打包成用于在 Web 浏览器中执行的分发字符串,与 JavaScript 环境集成。 该系统提供 Ruby 到 JavaScript 的编译功能以及编码和解码 Base64 数据的功能。
Implements a template system to generate markup using embedded Ruby logic.
Jbuilder 是一个用于 Ruby 的 JSON 模板引擎和构建器,提供了一种用于生成结构化 JSON 对象的领域特定语言(DSL)。它作为视图助手,使用逻辑、条件和循环将数据转换为 JSON 格式。 该项目通过使用局部模板(partials)和嵌套对象来构建复杂的数据结构,以保持模块化。它包括运行时键转换功能,允许在不同的命名约定(如蛇形命名法和驼峰命名法)之间转换属性键。 该系统支持动态 JSON 结构化,能够定义运行时键并管理 null 值的输出。它还提供了一种缓存渲染后的 JSON 片段的机制,以减少重复处理。
Implements a builder-style domain specific language for generating structured JSON objects through a Ruby-based template system.
Haml is a Ruby HTML template engine and server-side rendering library. It functions as an HTML markup preprocessor that transforms a concise, indentation-based shorthand syntax into standard HTML and XHTML markup. The system uses hierarchical whitespace instead of explicit closing tags to define the structure of documents, reducing boilerplate during markup authoring. It integrates Ruby logic directly into templates to evaluate conditional statements, process dynamic data, and interpolate values. The engine provides tools for managing element attributes through hashes, controlling output whi
Implements a template system designed for the Ruby ecosystem that generates markup using embedded logic.