CtrlK
BlogDocsLog inGet started
Tessl Logo

tessl/npm-hoist-non-react-statics

Copies non-react specific statics from a child component to a parent component

95

1.09x
Overview
Eval results
Files

rubric.jsonevals/scenario-6/

{
  "context": "Evaluates how the solution uses hoist-non-react-statics to wrap components while preserving descriptor-based statics and skipping read-only collisions without errors. Focuses on accessor preservation and guarded hoisting rather than general code quality.",
  "type": "weighted_checklist",
  "checklist": [
    {
      "name": "Hoist usage",
      "description": "Imports and calls hoistNonReactStatics (or equivalent from hoist-non-react-statics) to copy statics onto the wrapper instead of manual assignment.",
      "max_score": 20
    },
    {
      "name": "Accessor kept",
      "description": "After hoisting, getter-based statics from the source remain accessors (checked via property descriptors) rather than being converted to plain values, demonstrating descriptor-aware copy.",
      "max_score": 30
    },
    {
      "name": "Non-enumerable",
      "description": "Preserves the non-enumerable flag of hoisted statics so wrapped component descriptors match the source (e.g., getter property stays non-enumerable).",
      "max_score": 20
    },
    {
      "name": "Read-only safe",
      "description": "Hoisting tolerates non-configurable or non-writable statics on the target/source (e.g., instrumentationTag) without throwing, leaving the target's existing value intact by relying on hoistNonReactStatics' guarded copy.",
      "max_score": 30
    }
  ]
}

Install with Tessl CLI

npx tessl i tessl/npm-hoist-non-react-statics

tile.json