securityos/node_modules/stylelint/lib/utils/isAfterComment.js

17 lines
335 B
JavaScript
Raw Normal View History

2024-09-06 15:32:35 +00:00
'use strict';
const isSharedLineComment = require('./isSharedLineComment');
/**
* @param {import('postcss').Node} node
*/
module.exports = function isAfterComment(node) {
const previousNode = node.prev();
if (!previousNode || previousNode.type !== 'comment') {
return false;
}
return !isSharedLineComment(previousNode);
};