Within my yarn.lock
file, there is a single reference to momentjs:
pikaday@^1.6.0:
version "1.6.1"
resolved "https://registry.yarnpkg.com/pikaday/-/pikaday-1.6.1.tgz#b91bcb9b8539cedd8dd6d08e4e7465e12095671b0"
optionalDependencies:
moment "2.x"
After deleting the entire node_modules
folder and the yarn.lock
file, I executed yarn --ignore-optional
. However, the new yarn.lock
generated still contains the same lines, prompting the installation of moment
in my node_modules directory, leading to its inclusion in my bundle.
The version of yarn being used is 0.27.5
.
How can I prevent the installation of this optional dependency?