Closed fahamidev closed 6 years ago
Same Issue, window is not defined
Did you figure out how to fix it?
@EhsanFahami Your example repository repeats the same problem: You are defining css rules twice.
See for yourself, add console.log(appConfig.module.rules)
in razzle.config.js
Now, if you debug your code you'll see that /home/ehsan/Desktop/with-redux-original/build/server.js:813
points to isOldIE
function, which you could then search node_modules
for to discover that it's being used by style-loader
.
Further investigation could then make you realize that style-loader
is for client only and you shouldn't include it in server bundle so the original code I proposed should check the target
and use different loaders on server.
Hola! So here's the deal, between open source and my day job and life and what not, I have a lot to manage, so I use a GitHub bot to automate a few things here and there. This particular GitHub bot is going to mark this as stale because it has not had recent activity for a while. It will be closed if no further activity occurs in a few days. Do not take this personally--seriously--this is a completely automated action. If this is a mistake, just make a comment, DM me, send a carrier pidgeon, or a smoke signal.
ProBot automatically closed this due to inactivity. Holler if this is a mistake, and we'll re-open it.
I don't suppose this has been solved. I checkout out 'razzle config-utils' @d4rky-pl but haven't been able to get your example to work from 297. I've been checking out a lot of solutions but they are either too old or not detailed enough (new to react, got a project with razzle to start...yay me). I don't want to give up since this seems simple enough to figure out once I know what I need in my razzle.config.js. I have my .css file in my project folder. I saw this solution by Jared Palmer but it seemed old, though I tried it and it did not work. This seemed to be the most insightful post (after all the other problems pointed here). Is that razzle.config.js in the example working now? I tried it and still had issues. I also went ahead and checked out the with-scss but it wasn't helpful. If you can just point me in the right way, I haven't needed a razzle.config.js before this issue so I figured I would just solve the error I am dealing with now and comeback to really dive deep into what I can do with the razzle.config.js later on. Thanks!
Hi everyone. I want to use
css
files from anywhere. And so I've used therazzle.config.js
file and made some adjustments to it.my config in the
razzle.config.js
file :and I encountered the following error after configuration:
There are two problems in the issue ( razzle/issues/34, razzle/issues/297 ), which is roughly the same problem and is related to this issue and I've read them.
@d4rky-pl And I've tried this solution and I'm faced with another error window is not defined :
I tried to resolve my issue in issue 297, but I preferred to check here. for example, I have placed the minimal github repository
Thanks for your guidance