File tree Expand file tree Collapse file tree 2 files changed +11
-9
lines changed
Expand file tree Collapse file tree 2 files changed +11
-9
lines changed Original file line number Diff line number Diff line change 1919 - name : Install dependencies
2020 run : yarn install --frozen-lockfile
2121
22- - name : Build React App
23- run : yarn build
22+ - name : Build React App with Dynamic PUBLIC_URL
23+ run : |
24+ echo "Building for /dev/${{ env.BRANCH_NAME}}/"
25+ PUBLIC_URL="/dev/${{ env.BRANCH_NAME}}/" yarn build
2426
2527 - name : Determine Branch Name
2628 id : get_branch
Original file line number Diff line number Diff line change @@ -4,13 +4,13 @@ import theme from "design/theme";
44import { BrowserRouter } from "react-router-dom" ;
55
66const App = ( ) => {
7- return (
8- < ThemeProvider theme = { theme } >
9- < BrowserRouter >
10- < Routes />
11- </ BrowserRouter >
12- </ ThemeProvider >
13- ) ;
7+ return (
8+ < ThemeProvider theme = { theme } >
9+ < BrowserRouter basename = { process . env . PUBLIC_URL } >
10+ < Routes />
11+ </ BrowserRouter >
12+ </ ThemeProvider >
13+ ) ;
1414} ;
1515
1616export default App ;
You can’t perform that action at this time.
0 commit comments