79335735

Date: 2025-01-07 11:02:49
Score: 0.5
Natty:
Report link

This is a working way how to enable typing of propTypes using JSDoc

import React, { PureComponent } from "react";
import PropTypes from "prop-types";

/**
 * @extends {PureComponent<PropTypes.InferProps<SomeComponent.propTypes>>}
 */
class SomeComponent extends PureComponent {
  // ...
}
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: constgen