AprilSylph / XKit-Rewritten

🧰 The enhancement suite for Tumblr's new web interface
GNU General Public License v3.0
274 stars 44 forks source link

Require jsdoc on exported util functions #1523

Open marcustyphoon opened 5 days ago

marcustyphoon commented 5 days ago

Description

Like #1522, except it doesn't require learning a new skill to understand.

As an obligatory followup to our discussion in https://github.com/AprilSylph/XKit-Rewritten/pull/1514#discussion_r1649783093, this adds "function expression" and "arrow function expression" to the list of function types the jsdoc/require-jsdoc eslint rule applies to. By default, it only applies to function declarations, which I think is very stupid.

That would mean we need to jsdoc a billion functions, which is silly; this therefore also filters the functions to only those exported from util modules.

Testing steps