mirror of
https://github.com/cheeaun/phanpy.git
synced 2024-11-21 16:55:25 +03:00
Use sonda for JS/CSS bundle analyzer
This commit is contained in:
parent
b70e31a517
commit
c6e562c62e
3 changed files with 7 additions and 0 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -27,6 +27,7 @@ dist-ssr
|
||||||
.env.dev
|
.env.dev
|
||||||
phanpy-dist.zip
|
phanpy-dist.zip
|
||||||
phanpy-dist.tar.gz
|
phanpy-dist.tar.gz
|
||||||
|
sonda-report.html
|
||||||
|
|
||||||
# Compiled locale files
|
# Compiled locale files
|
||||||
src/locales/*.js
|
src/locales/*.js
|
|
@ -65,6 +65,7 @@
|
||||||
"postcss": "~8.4.47",
|
"postcss": "~8.4.47",
|
||||||
"postcss-dark-theme-class": "~1.3.0",
|
"postcss-dark-theme-class": "~1.3.0",
|
||||||
"postcss-preset-env": "~10.0.8",
|
"postcss-preset-env": "~10.0.8",
|
||||||
|
"sonda": "^0.5.0",
|
||||||
"twitter-text": "~3.1.0",
|
"twitter-text": "~3.1.0",
|
||||||
"vite": "~5.4.10",
|
"vite": "~5.4.10",
|
||||||
"vite-plugin-generate-file": "~0.2.0",
|
"vite-plugin-generate-file": "~0.2.0",
|
||||||
|
|
|
@ -4,6 +4,7 @@ import { resolve } from 'path';
|
||||||
|
|
||||||
import { lingui } from '@lingui/vite-plugin';
|
import { lingui } from '@lingui/vite-plugin';
|
||||||
import preact from '@preact/preset-vite';
|
import preact from '@preact/preset-vite';
|
||||||
|
import { SondaRollupPlugin } from 'sonda';
|
||||||
import { uid } from 'uid/single';
|
import { uid } from 'uid/single';
|
||||||
import { defineConfig, loadEnv, splitVendorChunkPlugin } from 'vite';
|
import { defineConfig, loadEnv, splitVendorChunkPlugin } from 'vite';
|
||||||
import generateFile from 'vite-plugin-generate-file';
|
import generateFile from 'vite-plugin-generate-file';
|
||||||
|
@ -149,6 +150,10 @@ export default defineConfig({
|
||||||
type: 'module',
|
type: 'module',
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
SondaRollupPlugin({
|
||||||
|
detailed: true,
|
||||||
|
brotli: true,
|
||||||
|
}),
|
||||||
],
|
],
|
||||||
build: {
|
build: {
|
||||||
sourcemap: true,
|
sourcemap: true,
|
||||||
|
|
Loading…
Reference in a new issue