项目多了之后,就会遇到这种问题:

» yarn dev
yarn run v1.22.11
error Command "dev" not found.
info Visit yarnpkg.com/en/docs/cli/run for documentation about this command.

» yarn serve
yarn run v1.22.11
error Command "dev" not found.
info Visit yarnpkg.com/en/docs/cli/run for documentation about this command.

啊,我知道了。
» yarn start

#工程师日常 #程序员日常

Follow

@meina 我也沒搞明白配置在哪裡,有的dev,有的serve

@nil 在 package.json 里的 scripts 字段里。

如果我没记错的话,15年我开始学前端的时候,大家基本都是dev的。我用Vue比较多。然后我就看 Vue(其实是vue-cli)升级迭代之后开始用 serve。 它两个的前后顺序我是又感觉的。

但没印象 start 是什么时候开始流行起来的。

妈的好烦。这样我每次切项目都得看一下命令是啥, 好烦。

Sign in to participate in the conversation
CleverLibre Social

CleverLibre Social is an inclusive social instance for open discussion, learning, and community.
All cultures welcome.
Hate speech and harassment strictly forbidden.