Comments (3)
I'm glad to hear someone is using this in production! I honestly haven't been sure this would be suitable for more than hobby projects so it's heartening to get feedback that this is a viable production solution 😍
As to your question, I played around a little bit and unfortunately the current version of the library requires that reactjs/build/asset-manifest.json be present even after running collectstatic
. Everything else in the reactjs/build/ folder can be deleted, it's just asset-manifest.json that needs to remain.
...Which feels like a bug to me. Digging a bit deeper, since asset-manifest.json gets scooped up in the collectstatic
command, this library's CRAManifestFinder
can be updated to try and access the one in the static/ folder if the one in reactjs/build/ is missing, and then fail. This would make it possible to completely remove the build/ directory!
Let me see what I can do...
from django-cra-helper.
@vsobotka I just published django-cra-helper==1.2.3
to PyPI that should allow you to completely remove your reactjs/build/ directory provided you've run collectstatic
and confirmed that asset-manifest.json exists in STATIC_ROOT
. Give it a try and let me know what you think.
from django-cra-helper.
@MasterKale Hi, thanks for such a quick response and action! Taking the STATIC_ROOT
into consideration makes a perfect sense and is the ideal solution. I am currently testing it in the staging environment and it looks it is working perfectly. Thanks a lot!
I honestly haven't been sure this would be suitable for more than hobby projects so it's heartening to get feedback that this is a viable production solution 😍
I have no idea how else would I do that to be honest. We are using it for www.simcompanies.com roughly for about 9 months now and it has worked wonders. So really thank you for this amazing plugin!
from django-cra-helper.
Related Issues (16)
- Missing service worker support HOT 3
- The helper doesn't seem to work when there is a "homepage" setting in package.json HOT 3
- Live reloading requests for hot-update paths fail HOT 3
- static assets from CRA not being collected HOT 2
- How to add routes from react-router-dom? HOT 1
- Webpack compile error in both Safar and Firefox latest version HOT 2
- Question on accessing images in public/ folder. HOT 2
- TypeError: can only concatenate tuple (not "list") to tuple HOT 4
- CRA over external interface dev build HOT 1
- Document that the `FileSystemFinder` needs to be in `STATICFILES_FINDERS` HOT 2
- Investigate possibility of replacing custom template tag with Django's `json_script` HOT 1
- Liveserver integration does not work with [email protected] HOT 1
- Code splitting support for live server HOT 2
- Asset loading error when CRA liveserver not found HOT 7
- "The development server has disconnected" HOT 7
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-cra-helper.