reactjs - 通知最大文件限制
问题描述
我在 docker 环境中用电子编程反应应用程序。当我尝试时npm run dev
,出现以下错误:
Error from chokidar (/home/app/mountpoint/Matres-GUI/node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime): Error: ENOSPC: System limit for number of file watchers reached, watch '/home/app/mountpoint/Matres-GUI/node_modules/@pmmmwh/react-refresh-webpack-plugin/lib/runtime'
但我无法增加 inotify 观察者的数量,因为我没有编辑权限/etc/sysctl.conf
有没有办法放弃所有的观察者设置?
解决方案
终于在这里找到了解决方案
只需添加CHOKIDAR_USEPOLLING=true npm start
到本地.env
文件
推荐阅读
- php - Join between two table don't return rows with no link between the tables
- excel - 如何将数组和单个单元格作为参数传递
- ruby-on-rails - 成功构建但进程以状态 1 退出,在 heroku 上部署 rails 应用程序
- javascript - 如何获取嵌套表单的动态 ID?
- highcharts - 高图表:饼图中的逗号千位分隔符。你好吗?
- c++ - 返回 0、1、-1 时需要澄清(不在主目录中)
- spss - 通用线性模型 - 使用协变量重复测量,估计边际均值没有调整?漏洞?
- database - 使用 Google 表格将数据从一列拆分到不同的表格中
- powerapps - 与 CDS 时区无关的日期时间字段在 Powerapps 中不可用
- azure - 应用程序设置 Azure