chore: unify build output for both npm and bundle

This commit is contained in:
2026-04-26 23:02:36 +03:30
parent 5fd8f9b047
commit 8134911e17
5 changed files with 1104 additions and 29 deletions

View File

@@ -1,25 +1,34 @@
{
"name": "VideoPlayer",
"version": "0.0.1",
"description": "VideoPlayer (vp) is a private project at db company to handle hls streams in a modular beautiful html5 video player.",
"keywords": [],
"repository": {
"type": "git",
"url": "VideoPlayer"
"name": "@db/VP",
"version": "0.0.2",
"type": "module",
"main": "./dist/video-player.cjs.js",
"module": "./dist/video-player.es.js",
"types": "./dist/index.d.ts",
"exports": {
".": {
"import": "./dist/video-player.es.js",
"require": "./dist/video-player.cjs.js",
"types": "./dist/index.d.ts"
},
"./style.css": "./dist/style.css"
},
"license": "MIT",
"author": "db",
"type": "commonjs",
"main": "index.ts",
"files": [
"dist",
"README.md"
],
"scripts": {
"dev": "vite build --watch",
"build": "tsc",
"bundle": "vite build",
"test": "vitest",
"preview": "vite preview"
"build": "tsc && vite build",
"test": "vitest run",
"test:watch": "vitest",
"lint": "eslint . --ext .ts",
"preview": "vite preview",
"prepublishOnly": "npm run lint && npm run test && npm run build"
},
"devDependencies": {
"@types/node": "^25.6.0",
"eslint": "^9.39.4",
"typescript": "^6.0.3",
"vite": "^8.0.9",
"vitest": "^4.1.5"