File tree Expand file tree Collapse file tree 6 files changed +47
-9
lines changed Expand file tree Collapse file tree 6 files changed +47
-9
lines changed Original file line number Diff line number Diff line change @@ -22,3 +22,4 @@ dist-ssr
22
22
* .njsproj
23
23
* .sln
24
24
* .sw ?
25
+ bundlemeta.json
Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ import { defineConfig } from '@lingui/cli';
3
3
export default defineConfig ( {
4
4
catalogs : [
5
5
{
6
+ exclude : [ 'src/components/trans/trans.tsx' ] ,
6
7
include : [ 'src' ] ,
7
8
path : '<rootDir>/src/locales/{locale}/messages' ,
8
9
} ,
Original file line number Diff line number Diff line change 97
97
"ts-node" : " ^10.9.2" ,
98
98
"typescript" : " ^5.7.2" ,
99
99
"typescript-eslint" : " ^8.18.2" ,
100
- "vite" : " ^6.0.5"
100
+ "vite" : " ^6.0.5" ,
101
+ "vite-plugin-bundlesize" : " ^0.1.0"
101
102
},
102
103
"lint-staged" : {
103
104
"*.{js,jsx,ts,tsx}" : [
Original file line number Diff line number Diff line change @@ -16,19 +16,19 @@ msgstr ""
16
16
#. js-lingui-explicit-id
17
17
#: src/App.tsx:16
18
18
#: src/App.tsx:19
19
- msgid "tgb"
20
- msgstr "Edit <0>src/App.tsx</0> and save to test HMR"
19
+ #~ msgid "tgb"
20
+ #~ msgstr "Edit <0>src/App.tsx</0> and save to test HMR"
21
21
22
22
#. js-lingui-explicit-id
23
23
#: src/App.tsx:25
24
24
#: src/App.tsx:31
25
- msgid "test"
26
- msgstr "New Trans to test watcher!"
25
+ #~ msgid "test"
26
+ #~ msgstr "New Trans to test watcher!"
27
27
28
28
#: src/App.tsx:28
29
- msgid "Another New Trans to test watcher!"
30
- msgstr "Another New Trans to test watcher!"
29
+ #~ msgid "Another New Trans to test watcher!"
30
+ #~ msgstr "Another New Trans to test watcher!"
31
31
32
32
#: src/App.tsx:25
33
- msgid "New Trans to test watcher!"
34
- msgstr "New Trans to test watcher!"
33
+ #~ msgid "New Trans to test watcher!"
34
+ #~ msgstr "New Trans to test watcher!"
Original file line number Diff line number Diff line change @@ -2,13 +2,34 @@ import { lingui } from '@lingui/vite-plugin';
2
2
import react from '@vitejs/plugin-react-swc' ;
3
3
import path from 'path' ;
4
4
import { defineConfig } from 'vite' ;
5
+ import bundlesize from 'vite-plugin-bundlesize' ;
5
6
6
7
// https://vite.dev/config/
7
8
export default defineConfig ( {
9
+ build : {
10
+ sourcemap : 'hidden' ,
11
+ target : 'esnext' ,
12
+ } ,
13
+ css : {
14
+ preprocessorOptions : {
15
+ scss : {
16
+ api : 'modern-compiler' ,
17
+ } ,
18
+ } ,
19
+ } ,
8
20
plugins : [
9
21
react ( {
10
22
plugins : [ [ '@lingui/swc-plugin' , { } ] ] ,
11
23
} ) ,
24
+ bundlesize ( {
25
+ limits : [
26
+ {
27
+ limit : Infinity ,
28
+ name : '**/*' ,
29
+ } ,
30
+ ] ,
31
+ stats : 'all' ,
32
+ } ) ,
12
33
lingui ( ) ,
13
34
] ,
14
35
resolve : {
Original file line number Diff line number Diff line change @@ -8644,6 +8644,15 @@ varint@^6.0.0:
8644
8644
resolved "https://registry.yarnpkg.com/varint/-/varint-6.0.0.tgz#9881eb0ce8feaea6512439d19ddf84bf551661d0"
8645
8645
integrity sha512-cXEIW6cfr15lFv563k4GuVuW/fiwjknytD37jIOLSdSWuOI6WnO/oKwmP2FQTU2l01LP8/M5TSAJpzUaGe3uWg==
8646
8646
8647
+ vite-plugin-bundlesize@^0.1.0 :
8648
+ version "0.1.0"
8649
+ resolved "https://registry.yarnpkg.com/vite-plugin-bundlesize/-/vite-plugin-bundlesize-0.1.0.tgz#2c3c6bfa908d1a43ae6f428826af07abbaa558f7"
8650
+ integrity sha512-aaoVAijpSg7yFzveOX+KWul6QPk0YmuugGacSA4bnpErxoyXHAkGi02AEzx1qyt5AKMN8LG7bDLsYLW8mq2QUQ==
8651
+ dependencies :
8652
+ picomatch "^4.0.2"
8653
+ strip-ansi "^7.1.0"
8654
+ vlq "^2.0.4"
8655
+
8647
8656
vite@^6.0.5 :
8648
8657
version "6.0.5"
8649
8658
resolved "https://registry.yarnpkg.com/vite/-/vite-6.0.5.tgz#1d0fbdb3ffe61e944089abeddb7d2c509420acfd"
@@ -8655,6 +8664,11 @@ vite@^6.0.5:
8655
8664
optionalDependencies :
8656
8665
fsevents "~2.3.3"
8657
8666
8667
+ vlq@^2.0.4 :
8668
+ version "2.0.4"
8669
+ resolved "https://registry.yarnpkg.com/vlq/-/vlq-2.0.4.tgz#6057b85729245b9829e3cc7755f95b228d4fe041"
8670
+ integrity sha512-aodjPa2wPQFkra1G8CzJBTHXhgk3EVSwxSWXNPr1fgdFLUb8kvLV1iEb6rFgasIsjP82HWI6dsb5Io26DDnasA==
8671
+
8658
8672
vscode-json-languageservice@^4.1.6 :
8659
8673
version "4.2.1"
8660
8674
resolved "https://registry.yarnpkg.com/vscode-json-languageservice/-/vscode-json-languageservice-4.2.1.tgz#94b6f471ece193bf4a1ef37f6ab5cce86d50a8b4"
You can’t perform that action at this time.
0 commit comments