Closed tarngerine closed 1 year ago
You can add to the contexts
option something like the following:
contexts: [
'CallExpression[callee.name="observer"]',
],
To tweak the CallExpression further, you can introspect, using the @typescript-eslint/parser
, on sample AST using https://astexplorer.net .
Closing as this should resolve, though feel free to comment further as needed
Perfect, thank you! On Aug 16, 2023 at 1:19 PM -0500, Brett Zamir @.***>, wrote:
Closed #1144 as completed. — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
Motivation
Our codebase uses HoC (i.e. mobx observer) exports for our components, and we'd like
require-jsdoc
to properly flag a component export with no jsdoc comments:Current behavior
It doesn't trigger for this HoC pattern with these options:
Desired behavior
require-jsdoc should have an option for supporting regular assignment expressions with HoC