File tree Expand file tree Collapse file tree 2 files changed +4
-7
lines changed
Expand file tree Collapse file tree 2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change 2222 with :
2323 node-version : ${{ matrix.node-version }}
2424 - run : npm ci
25- - name : Build with GitHub Pages publicPath
26- run : npm run build
27- env :
28- PUBLIC_PATH : /mashlib/dist/
25+ - run : npm run build
2926 - run : npm run bundlesize
3027 - name : Save build
3128 if : matrix.node-version == 20
Original file line number Diff line number Diff line change @@ -23,9 +23,9 @@ const common = {
2323 target : 'web' ,
2424 output : {
2525 path : path . resolve ( process . cwd ( ) , 'dist' ) ,
26- // Use PUBLIC_PATH env var for deployment (e.g., '/mashlib/dist/' for GitHub Pages)
27- // Defaults to '/' for local development and production
28- publicPath : process . env . PUBLIC_PATH || '/ ',
26+ // 'auto' determines the public path at runtime based on the script's location
27+ // This works for both the HTML file and dynamically loaded chunks
28+ publicPath : 'auto ',
2929 library : {
3030 name : 'Mashlib' ,
3131 type : 'umd'
You can’t perform that action at this time.
0 commit comments