UNPKG

eslint-plugin-comment-length

Version:

An ESLint plugin that provides rules that limit the line length of your comments

20 lines (16 loc) 520 B
'use strict'; var isPunctuation = require('./is-punctuation.cjs'); function isAnotherWrapPointComing(currentLength, maxLength, wordsToCome) { for (const word of wordsToCome) { if (isPunctuation.isPunctuation(word.at(-1)) && word.length > 1) { return true; } currentLength += word.length + 1; if (currentLength >= maxLength) { return false; } } return false; } exports.isAnotherWrapPointComing = isAnotherWrapPointComing; //# sourceMappingURL=is-another-wrap-point-coming.cjs.map