@marko/language-tools 2.4.6 → 2.4.7
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 +7 -2
- package/dist/index.mjs +7 -2
- package/package.json +2 -2
package/dist/index.js
CHANGED
|
@@ -358,6 +358,8 @@ var Builder = class {
|
|
|
358
358
|
);
|
|
359
359
|
this.#comments = void 0;
|
|
360
360
|
return import_htmljs_parser.TagType.statement;
|
|
361
|
+
case "server":
|
|
362
|
+
case "client":
|
|
361
363
|
case "static":
|
|
362
364
|
this.#program.static.push(
|
|
363
365
|
this.#staticNode = {
|
|
@@ -1119,9 +1121,12 @@ function crawlProgramScope(parsed, scriptParser) {
|
|
|
1119
1121
|
case 16 /* AttrTag */: {
|
|
1120
1122
|
if (child.var) {
|
|
1121
1123
|
parentScope.bindings ??= {};
|
|
1122
|
-
const parsedFn = scriptParser.expressionAt(
|
|
1124
|
+
const parsedFn = scriptParser.expressionAt(
|
|
1125
|
+
child.var.value.start - 1,
|
|
1126
|
+
`(${read(child.var.value)})=>0`
|
|
1127
|
+
);
|
|
1123
1128
|
if (parsedFn) {
|
|
1124
|
-
const lVal = parsedFn.
|
|
1129
|
+
const lVal = parsedFn.params[0];
|
|
1125
1130
|
checkForMutations(parentScope, lVal);
|
|
1126
1131
|
for (const id of getVarIdentifiers(
|
|
1127
1132
|
parsed,
|
package/dist/index.mjs
CHANGED
|
@@ -319,6 +319,8 @@ var Builder = class {
|
|
|
319
319
|
);
|
|
320
320
|
this.#comments = void 0;
|
|
321
321
|
return TagType.statement;
|
|
322
|
+
case "server":
|
|
323
|
+
case "client":
|
|
322
324
|
case "static":
|
|
323
325
|
this.#program.static.push(
|
|
324
326
|
this.#staticNode = {
|
|
@@ -1080,9 +1082,12 @@ function crawlProgramScope(parsed, scriptParser) {
|
|
|
1080
1082
|
case 16 /* AttrTag */: {
|
|
1081
1083
|
if (child.var) {
|
|
1082
1084
|
parentScope.bindings ??= {};
|
|
1083
|
-
const parsedFn = scriptParser.expressionAt(
|
|
1085
|
+
const parsedFn = scriptParser.expressionAt(
|
|
1086
|
+
child.var.value.start - 1,
|
|
1087
|
+
`(${read(child.var.value)})=>0`
|
|
1088
|
+
);
|
|
1084
1089
|
if (parsedFn) {
|
|
1085
|
-
const lVal = parsedFn.
|
|
1090
|
+
const lVal = parsedFn.params[0];
|
|
1086
1091
|
checkForMutations(parentScope, lVal);
|
|
1087
1092
|
for (const id of getVarIdentifiers(
|
|
1088
1093
|
parsed,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@marko/language-tools",
|
|
3
3
|
"description": "Marko Language Tools",
|
|
4
|
-
"version": "2.4.
|
|
4
|
+
"version": "2.4.7",
|
|
5
5
|
"bugs": "https://github.com/marko-js/language-server/issues/new?template=Bug_report.md",
|
|
6
6
|
"peerDependencies": {
|
|
7
7
|
"@marko/compiler": "^5.28.4"
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"dependencies": {
|
|
10
10
|
"@babel/parser": "^7.26.2",
|
|
11
11
|
"@luxass/strip-json-comments": "^1.3.2",
|
|
12
|
-
"htmljs-parser": "^5.5.
|
|
12
|
+
"htmljs-parser": "^5.5.3",
|
|
13
13
|
"relative-import-path": "^1.0.0"
|
|
14
14
|
},
|
|
15
15
|
"devDependencies": {
|