Deployed ReactJs to Vercel, when click on any link it shown 404 Page Not Found
2025-01-18
Solved You are running `create-react-app` 5.0.0, which is behind the latest release (5.0.1)
2022-04-13
最近用了NodeJs Express 來做 Web App 的 Backend 用左 port 3000 而create-react-app 既 default port 又係 3000 怎樣可以改變create-react-app 既 port 呢 解決方法: 十分簡單… 我們只需要在 package.json 上既 scripts section start 上加上 set PORT=[PORT_YOU_WANTED] 便可 e.g.
2021-01-30
最近嘗試在 React App 上加入 Coverage Report… 可能是因為是用了create-react-app 所以在使用 yarn test 的時候便自己加了 watch mode.. create-react-app test 當有 code change 時便會再 test 一次.. 在 console 上不停顯示 code coverage 便很繁忙了 如果可以在 run code coverage report 時停了 watch 便好
2020-08-12
係 GitHub 用 GitHub Page Host 果個 ReactJs Project 由於個 Page 係 Subfolder 同 存放 e.g. https://sharechiwai.github.io/code-playground 而不是 https://sharechiwai.github.io 所以當我 reploy ReactApp 到 GitHub Page 上時 當 click 去任何一條 Link 時..他沒有 suffix code-playground e.g.(contact) 便 navigate 去了 https://sharechiwai.github.io/contact 而不是很聰明地 去 https://sharechiwai.github.io/code-playground/contact
2020-08-10
用了 ReactJS 一段時間…想看看有沒有更新可以使用.. 希望可以使用 yarn upgrade 來更新… 但是更新了 package.json 的 dependencies 之後便出現了很多webpack 的 error 最後到了create-react-app page 的 CHANGELOG.md …跟著他的 migration guide 便可以更新到了… 原來解決方法十分簡單… 我們只需要跟著 mirgration guide 的 command 來更新 react-script 便可以 e.g.
2020-05-03
剛剛在寫 reactjs publish 上去 Firebase 之後出現了以一的 error message `` 之後便顯示唔到這個 react page 了 做了一會 research 之後發現應該是 redux compose 既問題 解決方法: 我改了之前的 const store = createStore( reducers, initialState, compose( applyMiddleware(...middleware), window.__REDUX_DEVTOOLS_EXTENSION__ && window.__REDUX_DEVTOOLS_EXTENSION__() ) ); 改成這樣便可以了 const store = createStore( reducers, initialState, compose( applyMiddleware(...middleware), window.REDUX_DEVTOOLS_EXTENSION ? window.REDUX_DEVTOOLS_EXTENSION() : (f) => f ) ); Hope you find it useful
2020-05-02
最近使用了 ASP.Net Core 的 SPA Template 來學習 ReactJs 因為我可以使用 ASP.Net Core 來做 Web API.. 而 ReactJs 來做 Web Front End 之後便可以 deploy 到 Azure 十分方便.. 又可以很快看到效果 ASP.Net Core App can NOW be deploy to Azure – (Azure web app)
2017-06-04