Updated the package.json

This commit is contained in:
Sambo Chea 2022-05-17 08:44:41 +07:00
parent ea06b0d706
commit d2838808b8
Signed by: sombochea
GPG Key ID: 3C7CF22A05D95490
3 changed files with 6 additions and 22 deletions

View File

@ -1,6 +1,6 @@
{ {
"name": "@cubetiq/muui", "name": "@cubetiq/muui",
"version": "0.0.1-alpha.1", "version": "0.0.1-alpha.2",
"author": { "author": {
"name": "Sambo Chea", "name": "Sambo Chea",
"email": "sombochea@cubetiqs.com" "email": "sombochea@cubetiqs.com"
@ -27,12 +27,7 @@
], ],
"scripts": { "scripts": {
"dev": "vite", "dev": "vite",
"build": "tsc && vite build", "build": "tsc && vite build"
"preview": "vite preview",
"test": "vitest run",
"watch": "vitest",
"coverage": "vitest run --coverage",
"prepack": "json -f package.json -I -e \"delete this.devDependencies; delete this.dependencies\""
}, },
"peerDependencies": { "peerDependencies": {
"@emotion/react": "^11.x", "@emotion/react": "^11.x",
@ -49,12 +44,9 @@
"@vitejs/plugin-react": "^1.3.0", "@vitejs/plugin-react": "^1.3.0",
"eslint": "^8.15.0", "eslint": "^8.15.0",
"eslint-plugin-react": "^7.29.4", "eslint-plugin-react": "^7.29.4",
"jsdom": "^19.0.0",
"json": "^11.0.0",
"typescript": "^4.6.3", "typescript": "^4.6.3",
"vite": "^2.9.9", "vite": "^2.9.9",
"vite-plugin-dts": "^1.1.1", "vite-plugin-dts": "^1.1.1",
"vitest": "^0.12.6"
}, },
"browserslist": { "browserslist": {
"production": [ "production": [
@ -93,4 +85,4 @@
"publishConfig": { "publishConfig": {
"access": "public" "access": "public"
} }
} }

View File

@ -8,13 +8,13 @@ export default defineConfig({
build: { build: {
lib: { lib: {
entry: path.resolve(__dirname, "src/lib/index.ts"), entry: path.resolve(__dirname, "src/lib/index.ts"),
name: "CUBETIQ MUUI", name: "muui",
formats: ['es', 'umd'], formats: ['es', 'umd'],
fileName: (format) => `muui-vite.${format}.js`, fileName: (format) => `muui.${format}.js`,
}, },
rollupOptions: { rollupOptions: {
// externalize deps that shouldn't be bundled // externalize deps that shouldn't be bundled
external: ["react", "react-dom"], external: ["react", "react-dom", "@emotion/react", "@emotion/styled", "@mui/icons-material", "@mui/material"],
output: { output: {
// Provide global variables to use in the UMD build for externalized deps // Provide global variables to use in the UMD build for externalized deps
globals: { globals: {

View File

@ -1,8 +0,0 @@
import { defineConfig } from "vite";
export default defineConfig({
test: {
globals: false,
environment: "jsdom",
},
});