rsnext/packages/next-swc
Shu Ding 9fff7e321c
Finalize HOC support with server entries and add encodeReply & decodeReply (#47438)
Revert some code in #47379 and finalize HOC support. We should require
the HOC to return a "use server" function, so there's no need to compile
the function call specially now.

To make that wrapping logic work, we need to allow passing a server
reference to another server reference. This usually happens in the
function closure in the HOC case, but ideally it's also allowed to
directly pass it as an argument. This requires adding React server DOM's
`encodeReply` and `decodeReply` and other corresponding changes,
including adding `busboy` (can probably be vendored?) as we need to
parse the multipart body now.

fix NEXT-808 ([link](https://linear.app/vercel/issue/NEXT-808))
([link](https://linear.app/vercel/issue/NEXT-808))
2023-03-24 13:01:10 +01:00
..
.cargo next-swc: Switch to testing::fixture (#47183) 2023-03-17 06:18:25 +00:00
.config re-enable next-dev-tests (#47087) 2023-03-14 16:05:19 +01:00
crates Finalize HOC support with server entries and add encodeReply & decodeReply (#47438) 2023-03-24 13:01:10 +01:00
native Extract next-swc Rust code into its own package (#31635) 2021-11-21 12:59:56 +01:00
.rustfmt.toml Extract next-swc Rust code into its own package (#31635) 2021-11-21 12:59:56 +01:00
Cargo.lock improve source mapping of console output and errors (#47388) 2023-03-23 12:43:22 +00:00
Cargo.toml improve source mapping of console output and errors (#47388) 2023-03-23 12:43:22 +00:00
package.json v13.2.5-canary.16 2023-03-24 06:24:45 +00:00
README.md docs: add readme with development instructions for next/swc (#43834) 2022-12-08 13:38:44 +01:00
rust-toolchain Update Turbopack to 230309.2 (#46971) 2023-03-09 13:24:24 -08:00

@next/swc

This package is responsible for swc compilation customized for next.js

Development

Run tests

cargo test

# Update snapshots and fixtures for tests
UPDATE=1 cargo test

Format code before submitting code

cargo fmt

Build the binary to integrate with next.js

pnpm build-native