@playcademy/vite-plugin 0.0.1-beta.1 → 0.0.1-beta.2

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.
Files changed (2) hide show
  1. package/package.json +3 -2
  2. package/src/index.ts +4 -16
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@playcademy/vite-plugin",
3
3
  "type": "module",
4
- "version": "0.0.1-beta.1",
4
+ "version": "0.0.1-beta.2",
5
5
  "module": "src/index.ts",
6
6
  "exports": {
7
7
  ".": {
@@ -11,9 +11,10 @@
11
11
  },
12
12
  "scripts": {
13
13
  "build": "bun build.ts",
14
- "pub": "bun run build && bunx bumpp --no-tag --no-push && bun publish --access public"
14
+ "pub": "bun run build && bunx bumpp --no-tag --no-push -m \"chore(@playcademy/vite-plugin): release v{version}\" && bun publish --access public"
15
15
  },
16
16
  "devDependencies": {
17
+ "@playcademy/types": "latest",
17
18
  "@types/archiver": "^6.0.3",
18
19
  "@types/bun": "latest"
19
20
  },
package/src/index.ts CHANGED
@@ -1,11 +1,12 @@
1
1
  import path from 'node:path'
2
2
  import fs from 'node:fs/promises'
3
3
  import { createWriteStream } from 'node:fs'
4
- import type { Plugin, ResolvedConfig } from 'vite'
5
- import { ManifestV1Schema, type ManifestV1 } from '@playcademy/data/schemas'
6
4
  import archiver from 'archiver'
7
5
  import pc from 'picocolors'
8
6
 
7
+ import type { Plugin, ResolvedConfig } from 'vite'
8
+ import type { ManifestV1 } from '@playcademy/types'
9
+
9
10
  export interface PlaycademyPluginOptions {
10
11
  bootMode?: ManifestV1['bootMode']
11
12
  entryPoint?: string
@@ -46,21 +47,8 @@ async function generatePlaycademyManifest(
46
47
  createdAt: new Date().toISOString(),
47
48
  }
48
49
 
49
- const validation = ManifestV1Schema.safeParse(manifestData)
50
-
51
- if (!validation.success) {
52
- console.error(
53
- '[Playcademy] Error validating generated manifest data:',
54
- validation.error.flatten(),
55
- )
56
- config.logger.error(
57
- '[Playcademy] Failed to generate valid manifest file.',
58
- )
59
- throw new Error('[Playcademy] Manifest validation failed')
60
- }
61
-
62
50
  const manifestPath = path.resolve(outDir, 'playcademy.manifest.json')
63
- const manifestJson = JSON.stringify(validation.data, null, 2)
51
+ const manifestJson = JSON.stringify(manifestData, null, 2)
64
52
 
65
53
  await fs.writeFile(manifestPath, manifestJson)
66
54