rsnext/test/e2e/edge-runtime-uses-edge-light-import-specifier-for-packages/pages/index.js
Gal Schlezinger 282c1a0637
[edge] support edge-light exports when bundling edge functions (#45188)
This PR implements `edge-light` as a main field for bundling edge
functions as defined in https://runtime-keys.proposal.wintercg.org

Resolves EC-614

## Feature

- [ ] Implements an existing feature request or RFC. Make sure the
feature request has been accepted for implementation before opening a
PR.
- [ ] Related issues linked using `fixes #number`
- [ ]
[e2e](https://github.com/vercel/next.js/blob/canary/contributing/core/testing.md#writing-tests-for-nextjs)
tests added
- [ ] Documentation added
- [ ] Telemetry added. In case of a feature if it's used or not.
- [ ] Errors have a helpful link attached, see
[`contributing.md`](https://github.com/vercel/next.js/blob/canary/contributing.md)

---------
2023-02-16 13:30:34 -08:00

12 lines
341 B
JavaScript

import edgeLightPackage from 'my-edge-light-package'
import edgeLightPackageExports from 'my-edge-light-package-exports'
export const config = { runtime: 'experimental-edge' }
export default function Index() {
return (
<pre id="result">
{JSON.stringify({ edgeLightPackage, edgeLightPackageExports }, null, 2)}
</pre>
)
}