contentlayerdev / contentlayerdev/next-contentlayer-example

Example does not run on vercel edge?

Đang mở
#23 0 bình luận 0 reaction 0 người được giao Xem trên GitHub
Ngôn ngữ chính
TypeScript
Star
104
Fork
37
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

Here is the repo:
https://github.com/yongyi520/contentlayer-example

I have cloned this repo and simply added
`export const runtime = 'edge' // 'nodejs' (default) | 'edge'`

on all pages

When I tried to deploy it to vercel, I got this issue:
**EvalError: Code generation from strings disallowed for this context**
![Screenshot 2023-09-09 at 14 31 39](https://github.com/contentlayerdev/next-contentlayer-example/assets/10789851/1c8752d9-8842-4473-a427-7b18db36531a)

Everything works fine on nodejs serverless, but when it's on edge it throws error somehow

Is there a workaround for this?

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.