How to get Heroku to recognize a yarn.lock or package.json within a subdirectory (not root)

后端 未结 6 2235
终归单人心
终归单人心 2021-02-19 10:11

I have a Rails application using React, Webpack, and Yarn for the client side. I have everything relating to the client side within the /client directory. This includes my yarn.

6条回答
  •  名媛妹妹
    2021-02-19 10:45

    1. To use yarn to install your application's dependences

      a) yarn.lock should be present in root of the repo. yarn install b) package-lock.json should be removed git rm package-lock.json

    2. To use npm

      a) yarn.lock should be removed

    Source: https://devcenter.heroku.com/articles/ruby-support#installed-binaries

    https://docs.npmjs.com/files/package-lock.json

提交回复
热议问题