first commit

This commit is contained in:
2026-09-08 20:28:54 +08:00
commit 2ada8d3d5a
37380 changed files with 4886169 additions and 0 deletions
+17
View File
@@ -0,0 +1,17 @@
var map = require('./map');
var trim = require('./trim');
var regBlockCmt = /(\/\*[\s\S]*?\*\/)/gm;
exports = function(str) {
var ret = str.match(regBlockCmt);
if (!ret) return [];
ret = map(ret, function(comment) {
return trim(
map(comment.split('\n'), function(line) {
return trim(line).replace(/^\/\*+|\*+\/$|^\*+/g, '');
}).join('\n')
);
});
return ret;
};
module.exports = exports;