scancss
Version:
A robust CSS stylesheet statistics collector and analyzer
18 lines (13 loc) • 630 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.isShorthandProperty = isShorthandProperty;
var _cssShorthandPropertiesMap = require('../../constants/cssShorthandPropertiesMap');
var _rePrefixedString = require('../../constants/rePrefixedString');
function isShorthandProperty(property) {
if (_rePrefixedString.rePrefixedString.test(property)) {
return Object.keys(_cssShorthandPropertiesMap.cssShorthandPropertiesMap).includes(property.replace(_rePrefixedString.rePrefixedString, ''));
}
return Object.keys(_cssShorthandPropertiesMap.cssShorthandPropertiesMap).includes(property);
}