Sha*_*man 7 npm-scripts codesandbox
我正在尝试在codesandbox 中运行json-servernpm。我创建了一个普通项目并添加了对package.json. 我必须运行一个脚本json-server --watch db.json。
Codesandbox 有没有办法运行脚本?
小智 3
您需要使用像Node这样的容器沙箱,以便能够运行 json-server 并设置您自己的脚本。
以下是有关 CodeSandbox 上可用的不同类型沙箱的更多信息: https: //codesandbox.io/docs/environment
顺便说一句,我们有一个您可能感兴趣的 json-server 模板: https: //codesandbox.io/s/json-server-1i5z0