新生成的 Rails 7.0 启动时出现 esbuild 选项错误。
rails new [project name] --javascript=esbuild --css=tailwind
在创建一个新的 rails 7 项目时,我尝试使用bin/dev
which uses now uses foreman 启动应用程序。但是,它会因“找不到错误命令“build”而出错。
bin/dev
!10520
16:07:31 web.1 | started with pid 53018
16:07:31 js.1 | started with pid 53019
16:07:31 css.1 | started with pid 53020
16:07:32 js.1 | yarn run v1.22.17
16:07:32 css.1 | yarn run v1.22.17 **************
16:07:32 js.1 | error Command "build" not found. <== *****THIS*****
16:07:32 js.1 | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
16:07:32 css.1 | error Command "build:css" not found.
16:07:32 css.1 | info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
16:07:33 css.1 | exited with code 1
16:07:33 system | sending SIGTERM to all processes
16:07:33 js.1 | exited with code 1
16:07:33 web.1 | terminated by SIGTERM