You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We added the fast path for c.json() in #4707. It uses Response.json() in the fast path. It seems good, but sometimes the behavior of Response.json() differs across runtimes. For example, c.json(undefined). The result, the PR #4756, is created.
Now, I revert the PR #4707 and disable the fast path for c.json(). We can keep the fast path logic without Response.json(), but if so, the bundle size will increase slightly. For now, revert.
The author should do the following, if applicable
Add tests
Run tests
bun run format:fix && bun run lint:fix to format the code
✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.48%. Comparing base (2de30d7) to head (8d9f1e6). ⚠️ Report is 3 commits behind head on main.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We added the fast path for
c.json()in #4707. It usesResponse.json()in the fast path. It seems good, but sometimes the behavior ofResponse.json()differs across runtimes. For example,c.json(undefined). The result, the PR #4756, is created.Now, I revert the PR #4707 and disable the fast path for
c.json(). We can keep the fast path logic withoutResponse.json(), but if so, the bundle size will increase slightly. For now, revert.The author should do the following, if applicable
bun run format:fix && bun run lint:fixto format the code