react-timer-hook | React timer hook | Frontend Utils library
kandi X-RAY | react-timer-hook Summary
kandi X-RAY | react-timer-hook Summary
React timer hook
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of react-timer-hook
react-timer-hook Key Features
react-timer-hook Examples and Code Snippets
Community Discussions
Trending Discussions on react-timer-hook
QUESTION
This is my first time trying to deploy a React application. I use Heroku and I added the create-react-app
build pack to my settings in Heroku. The application is deploying fine except that when I go to inspect the application with Chrome's developer tools, all of the code is readable. Nothing is minimized and the deployment read out is stating that its about 64MB in size which is pretty sizeable considering this is a simple minesweeper game I wrote as I am currently learning React.
I see that I can run yarn build
locally for production files but Heroku should be doing that (and it claims to be doing it) in the deployment process. Here is the full deployment log (and the url to application is at the bottom of the log if you want to see for yourself that the code isn't compressed at all.
Also, I have both the heroku/nodejs
and create-react-app
build packs added.
ANSWER
Answered 2019-Oct-18 at 15:43By default Create-React-App
has GENERATE_SOURCEMAP
flag set to TRUE
.
It means that creating production build will generate additional source maps to your js files = you can see non-compiled code in Chrome's developer tools.
To fix that you should add GENERATE_SOURCEMAP=false
to your envs on Heroku or add into package.json
:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install react-timer-hook
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page