Skip to content

@blazetrails/actiontext ​

Rich text content and editing for Trails, mirroring the actiontext gem

MeasureValue
Rails counterpartactiontext v8.0.5.2
API methods matched100% (253 of 253)
Rails tests matched—
Ruby files ported29
Ruby files unported0
Measured atfe89b44726

Gaps by file ​

No gaps recorded for this package.

Missing methods ​

None recorded for this package.

Unported Ruby files ​

Every compared Ruby file has a TypeScript file.

Deviation receipts ​

JSDoc receipt tags in the package's source, by the receipt each carries.

TagPERMANENTCONVERGEABLEnone
@noRailsEquivalent700
@missingRailsCall100
@missingRailsArgs300
@inventedArm400
@inlinedFrom002
@internal0077

Permanently skipped tests ​

Ruby pattern matching has no port (assert_pattern, deconstruct_keys) (1)

Ratified deviations ​

Each rule below is ratified in the repository's CLAUDE.md files. The first paragraph is quoted; the link opens the full section at this build's commit.

Ruby pattern matching has no port (assert_pattern, deconstruct_keys) ​

Ruby's case/in and rightward => pattern matching (vendor/ruby/v3.3.11/compile.c, iseq_compile_pattern_each) are syntax: a pattern binds and destructures through deconstruct / deconstruct_keys and raises NoMatchingPatternKeyError on a miss. JS has no pattern syntax, and a pattern written as data or a predicate is a new mini-language Rails readers would not recognise. trails does not port Ruby pattern matching: Minitest's assert_pattern / refute_pattern have no trails counterpart, and the deconstruct_keys members already ported (Date, GlobalID, URI::GID, ruby-compat's Hash) stay as plain methods. A Rails test whose assertions are patterns (PatternMatchingTestCases, vendor/rails/v8.0.5.2/actionview/test/template/test_case_test.rb:490-516) is parked as it.skip under a PERMANENT-SKIP: line citing this section. Ruled by the operator on 2026-10-21.

CLAUDE.md →

RichText's blank? / present? / empty? read a loaded plain text ​

RichText delegates blank?, empty? and present? to to_plain_text (vendor/rails/v8.0.5.2/actiontext/app/models/action_text/rich_text.rb:89), which renders each attachment and so reaches a GlobalID lookup. That is async here, and Base declares isBlank / isPresent sync, as activesupport's isBlank(record) reads them. So the three predicates are sync and read the plain text the last await richText.toPlainText() computed for a body with the same HTML, and before_save awaits it after canonicalized, so a saved record answers them (ActiveStorage's presence validation of embeds' record reads blank?). A nil body answers blank with no load, and any other unloaded body raises RuntimeError, as attached/one.rb's unloaded attachment does (packages/activestorage/CLAUDE.md). has_rich_text's store_if_blank: false writer reads name? through the same predicate on the loaded association, and the async isName awaits the association and its plain text first. Ruled by the operator on 2026-11-13.

packages/actiontext/CLAUDE.md →

Source ​

packages/actiontext on GitHub →