Expressjs not loading stylesheets on heroku, giving 500 error

后端 未结 3 1123
说谎
说谎 2021-01-01 04:20

I\'m running an Expressjs installation on heroku, and it\'s not loading the stylesheets.

I hit ctrl+u and then click on the stylesheet link, and get this error:

3条回答
  •  借酒劲吻你
    2021-01-01 05:03

    I just had the same problem and found that running the following command (via Heroku CLI) worked for me:

    heroku config:add NODE_ENV=production

    This was in conjunction with specifying the versions of Node and NPM as Silas mentioned.

    (via http://quickleft.com/blog/getting-started-with-express-in-node)

提交回复
热议问题