Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error after "npm run ssr" - Can't set headers after they are sent. #54

Closed
yacineblr opened this issue Jul 30, 2018 · 2 comments
Closed

Comments

@yacineblr
Copy link

Hi, I have a problem launching the project with "npm run ssr" just after git clone project and npm install.
I haven't changed anything.

ORIGIN_URL=http://localhost:4000
[email protected] server /home/lenovo/Documents/tmp/unistarter
node server.js
listening on http://localhost:4000!
GET: /home: 113.256ms
Error: Can't set headers after they are sent.
at SendStream.headersAlreadySent (/home/lenovo/Documents/tmp/unistarter/node_modules/send/index.js:390:13)
at SendStream.send (/home/lenovo/Documents/tmp/unistarter/node_modules/send/index.js:618:10)
at onstat (/home/lenovo/Documents/tmp/unistarter/node_modules/send/index.js:730:10)
at ZoneDelegate.invokeTask (/home/lenovo/Documents/tmp/unistarter/node_modules/zone.js/dist/zone-node.js:421:31)
at Zone.runTask (/home/lenovo/Documents/tmp/unistarter/node_modules/zone.js/dist/zone-node.js:188:47)
at ZoneTask.invokeTask (/home/lenovo/Documents/tmp/unistarter/node_modules/zone.js/dist/zone-node.js:496:34)
at ZoneTask.invoke (/home/lenovo/Documents/tmp/unistarter/node_modules/zone.js/dist/zone-node.js:485:48)
at data.args.(anonymous function) (/home/lenovo/Documents/tmp/unistarter/node_modules/zone.js/dist/zone-node.js:1317:25)
at FSReqWrap.oncomplete (fs.js:153:5)

My config is:
Ubuntu 16.04
Node v8.11.3
Npm 5.6.0

@Gorniv
Copy link
Member

Gorniv commented Aug 20, 2018

angular/zone.js#491

@shahbazkhan054
Copy link

Please check the express settings for redirection. It's getting redirected by your node or nginx server.

@Gorniv Gorniv closed this as completed Apr 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants