vue-hook-optimizer 0.0.50 → 0.0.52
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +6 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -0
- package/dist/index.mjs.map +1 -1
- package/package.json +16 -16
package/dist/index.js
CHANGED
@@ -177,12 +177,18 @@ var NodeCollection = class {
|
|
177
177
|
function getComment(node) {
|
178
178
|
let comment = "";
|
179
179
|
node.leadingComments?.forEach((_comment) => {
|
180
|
+
if (_comment.loc.end.line > node.loc.start.line) {
|
181
|
+
return;
|
182
|
+
}
|
180
183
|
if (_comment.value.trim().startsWith("*")) {
|
181
184
|
comment += `${_comment.value.trim().replace(/^[\s]*\*+[\s]*\**/gm, "").trim()}
|
182
185
|
`;
|
183
186
|
}
|
184
187
|
});
|
185
188
|
node.trailingComments?.forEach((_comment) => {
|
189
|
+
if (_comment.loc.end.line > node.loc.start.line) {
|
190
|
+
return;
|
191
|
+
}
|
186
192
|
if (_comment.value.trim().startsWith("*")) {
|
187
193
|
comment += `${_comment.value.trim().replace(/^[\s]*\*+[\s]*\**/gm, "").trim()}
|
188
194
|
`;
|