javascript - 超过 joi.string().base64() 的最大调用堆栈大小
问题描述
我收到下一个错误:
node_modules/joi/lib/types/string/index.js:464
if (regex.test(value)) {
^
RangeError: Maximum call stack size exceeded
at RegExp.test (<anonymous>)
对于代码:
const res = validate({ body: request }, {
body: joi.object({
image: joi.string().base64() // image base64 size in near 4MB
如何解决此限制错误?
解决方案
推荐阅读
- google-cloud-platform - 创建 ServiceAccountCredential FromServiceAccountData 时应该如何设置“范围”
- android - 在 ios 构建中无需按下绿色按钮即可直接调用
- spring-boot - 在控制器上运行应用程序
- python - 当这些方法应用于 True 值时,unittest 模块中的 assertIs 和 assertTrue 有什么区别?
- json - 读取 API 数据并从命名空间中提取图像
- python - 检查文件是否在python中共享相同的结尾
- animation - 如何在 Julia 中绘制多个 3D 轨迹(大概使用 for 循环?)——还有,如何随着时间的推移制作动画?
- javascript - 如何使用 Array.prototype.splice() 方法将元素推送到数组?
- c# - 如何在 C# Windows 服务应用程序中使用 Win32Api
- python - 无法在 python 中使用 firebase admin sdk 比较密码