Skip to content

gsap_non_transform_motion: lifecycle (sunset) + cross-repo enforcement follow-ups #1789

Description

@vanceingalls

Tracked follow-ups for the gsap_non_transform_motion lint rule shipped in #1779, so the deliberate deferrals there have an owner rather than living only as code comments.

1. Sunset coupling — pin the deferred refactor debt to the html-in-canvas render outcome

The rule's premise is the screenshot-capture path's integer-pixel snap. #1779's PR body states the intended lifecycle: when drawElement html-in-canvas becomes the default render path (#1295 / #1444), layout-prop animation stops stuttering everywhere — at that point downgrade the rule to a warning (or retire it).

That is the right call if html-in-canvas becomes universal. If it instead ships gated behind a flag indefinitely (cohort rollout, fallback for unsupported browsers), the rule stays load-bearing forever and the intentionally deferred refactor debt accumulates with no trigger to pay it down:

  • Two-source tween merge block duplicated between gsap_non_transform_motion and gsap_css_transform_conflict (packages/lint/src/rules/gsap.ts).
  • tagsByToken reimplements tagSimpleSelectors(); element→token index not shared between the two GSAP rules.
  • Efficiency: tagsByToken / layoutSubtreeRanges built before the gsap.timeline guard; per-script acorn parse + stripJsComments + standalone-call scan are uncached and duplicated across rules.
  • gsap_css_transform_conflict has no html-in-canvas exemption, so it can false-fire on the same <canvas layoutsubtree> elements the new rule exempts.
  • Decide severity: keep hard error, or make it config/context-driven keyed on the active render path.

Action: when #1295 / #1444 resolve (default vs flag-gated), decide retire-vs-downgrade and either delete the rule or pay down the debt above.

2. Cross-repo enforcement is implicit

@hyperframes/lint ships as a published package, but neither heygen-cli nor hyperframes-gemini-agent depend on it. Composition-generating agents (Claude / Gemini) therefore won't catch a left:/top:/letterSpacing: tween at generation time — only when the resulting HTML hits the HF runtime / capture engine where the rule runs.

Not a blocker (the rule fires where it matters), but "the rule lives in HF" is not "all HF-producing tools enforce it."

  • Import @hyperframes/lint (or run hyperframes lint) in the codegen path of heygen-cli and hyperframes-gemini-agent as a pre-publish / post-generation hook, so generated compositions are linted before they ship.

Follow-up to #1779. Related: #1295, #1444.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions