mirror of
https://github.com/robonen/tools.git
synced 2026-03-20 10:54:44 +00:00
feat(packages/stdlib): base vite config
This commit is contained in:
@@ -4,7 +4,15 @@
|
||||
"version": "1.0.0",
|
||||
"license": "UNLICENSED",
|
||||
"description": "",
|
||||
"keywords": [],
|
||||
"keywords": [
|
||||
"stdlib",
|
||||
"utils",
|
||||
"tools",
|
||||
"helpers",
|
||||
"math",
|
||||
"algorithms",
|
||||
"data-structures"
|
||||
],
|
||||
"author": "Robonen Andrew <robonenandrew@gmail.com>",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
@@ -19,26 +27,28 @@
|
||||
"files": [
|
||||
"dist"
|
||||
],
|
||||
"main": "./dist/index.cjs",
|
||||
"module": "./dist/index.js",
|
||||
"types": "./dist/index.d.ts",
|
||||
"main": "./dist/stdlib.umd.js",
|
||||
"module": "./dist/stdlib.js",
|
||||
"types": "./dist/stdlib.d.ts",
|
||||
"exports": {
|
||||
".": {
|
||||
"import": "./dist/index.js",
|
||||
"require": "./dist/index.cjs",
|
||||
"types": "./dist/index.d.ts"
|
||||
"import": "./dist/stdlib.js",
|
||||
"require": "./dist/stdlib.umd.js",
|
||||
"types": "./dist/stdlib.d.ts"
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"test": "echo \"Error: no test specified\" && exit 1",
|
||||
"test": "vitest",
|
||||
"coverage": "vitest run --coverage",
|
||||
"dev": "vite",
|
||||
"build": "vite build",
|
||||
"preview": "vite preview"
|
||||
"build": "vite build"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@robonen/tsconfig": "workspace:*",
|
||||
"@vitest/coverage-v8": "^1.4.0",
|
||||
"pathe": "^1.1.2",
|
||||
"vite": "^5.2.8",
|
||||
"vite-plugin-dts": "^3.8.1",
|
||||
"pathe": "^1.1.2"
|
||||
"vitest": "^1.4.0"
|
||||
}
|
||||
}
|
||||
@@ -3,12 +3,22 @@ import dts from 'vite-plugin-dts';
|
||||
import { resolve } from 'pathe';
|
||||
|
||||
export default defineConfig({
|
||||
build: {
|
||||
lib: {
|
||||
name: 'Stdlib',
|
||||
fileName: 'stdlib',
|
||||
entry: resolve(__dirname, './src/index.ts'),
|
||||
},
|
||||
},
|
||||
resolve: {
|
||||
alias: {
|
||||
'@': resolve(__dirname, './src'),
|
||||
},
|
||||
},
|
||||
plugins: [
|
||||
dts({ insertTypesEntry: true }),
|
||||
dts({
|
||||
insertTypesEntry: true,
|
||||
exclude: '**/*.test.ts',
|
||||
}),
|
||||
],
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user