Next.js Discord

Discord Forum

dynamic loading JS files in edge API route (to reduce edge code size)

arashi-dev posted this in #help-forum
Open in Discord
Is it possible to import a js file dynamically in the edge function route.js, to reduce the code size?

I've already did it. await import(path) works but it includes the path file in the bundled file, which doesn't help reducing the code size.

0 Replies