Skip to content

Commit 81a6731

Browse files
authored
refactor(marko-virtual): exports-based library packaging per Marko team guidance
packaging changed to the canonical Marko library shape per Marko team guidance (marko.json exports → built dist/tags, no tags-dir/script-lang, mtc-built declarations, in-repo consumers resolve tags from source via nested marko.json), plus the sideEffects fix
1 parent f13ecb6 commit 81a6731

71 files changed

Lines changed: 289 additions & 326 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{ "taglib-imports": ["../../../packages/marko-virtual/marko.json"] }
1+
{ "tags-dir": "../../../packages/marko-virtual/src/tags" }

examples/marko/chat-pretext/package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@
66
"dev": "marko-run dev",
77
"build": "marko-run build",
88
"preview": "marko-run preview",
9-
"test:e2e": "playwright test"
9+
"test:e2e": "playwright test",
10+
"test:types": "marko-type-check"
1011
},
1112
"dependencies": {
1213
"@chenglou/pretext": "^0.0.7",
@@ -15,6 +16,8 @@
1516
"marko": "^6.2.2"
1617
},
1718
"devDependencies": {
19+
"@marko/language-tools": "^2.6.2",
20+
"@marko/type-check": "3.1.1",
1821
"@playwright/test": "^1.53.1",
1922
"typescript": "5.6.3",
2023
"vite": "^6.4.2"

examples/marko/chat-pretext/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"src",
2020
"e2e",
2121
"playwright.config.ts",
22-
"vite.config.ts"
22+
"vite.config.ts",
23+
"../../../packages/marko-virtual/src/tags/**/*"
2324
]
2425
}

examples/marko/chat/marko.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{ "taglib-imports": ["../../../packages/marko-virtual/marko.json"] }
1+
{ "tags-dir": "../../../packages/marko-virtual/src/tags" }

examples/marko/chat/package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,17 @@
66
"dev": "marko-run dev",
77
"build": "marko-run build",
88
"preview": "marko-run preview",
9-
"test:e2e": "playwright test"
9+
"test:e2e": "playwright test",
10+
"test:types": "marko-type-check"
1011
},
1112
"dependencies": {
1213
"@marko/run": "^0.10.0",
1314
"@tanstack/marko-virtual": "^3.14.0",
1415
"marko": "^6.2.2"
1516
},
1617
"devDependencies": {
18+
"@marko/language-tools": "^2.6.2",
19+
"@marko/type-check": "3.1.1",
1720
"@playwright/test": "^1.53.1",
1821
"typescript": "5.6.3",
1922
"vite": "^6.4.2"

examples/marko/chat/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"src",
2020
"e2e",
2121
"playwright.config.ts",
22-
"vite.config.ts"
22+
"vite.config.ts",
23+
"../../../packages/marko-virtual/src/tags/**/*"
2324
]
2425
}

examples/marko/dynamic/marko.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{ "taglib-imports": ["../../../packages/marko-virtual/marko.json"] }
1+
{ "tags-dir": "../../../packages/marko-virtual/src/tags" }

examples/marko/dynamic/package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,17 @@
66
"dev": "marko-run dev",
77
"build": "marko-run build",
88
"preview": "marko-run preview",
9-
"test:e2e": "playwright test"
9+
"test:e2e": "playwright test",
10+
"test:types": "marko-type-check"
1011
},
1112
"dependencies": {
1213
"@marko/run": "^0.10.0",
1314
"@tanstack/marko-virtual": "^3.14.0",
1415
"marko": "^6.2.2"
1516
},
1617
"devDependencies": {
18+
"@marko/language-tools": "^2.6.2",
19+
"@marko/type-check": "3.1.1",
1720
"@playwright/test": "^1.53.1",
1821
"typescript": "5.6.3",
1922
"vite": "^6.4.2"

examples/marko/dynamic/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
"src",
2020
"e2e",
2121
"playwright.config.ts",
22-
"vite.config.ts"
22+
"vite.config.ts",
23+
"../../../packages/marko-virtual/src/tags/**/*"
2324
]
2425
}

examples/marko/fixed/marko.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
{ "taglib-imports": ["../../../packages/marko-virtual/marko.json"] }
1+
{ "tags-dir": "../../../packages/marko-virtual/src/tags" }

0 commit comments

Comments
 (0)