yarbsemaj / sveltekit-adapter-lambda

An adapter to build a SvelteKit app into a lambda ready for deployment with lambda proxy via the Serverless Framework or CDK.
https://www.npmjs.com/package/@yarbsemaj/adapter-lambda
MIT License
77 stars 16 forks source link

Building fails. #8

Closed ivands closed 2 years ago

ivands commented 2 years ago

When building I get the following error.

build/server/_serverless.js:2:21: error: Could not resolve "../index.js"
DanielRios549 commented 2 years ago

The same here

yarbsemaj commented 2 years ago

Hi @ivands @DanielRios549, Thanks for taking an interest in my project.

I think the issue may be the version of my adapter, and the version of svelte kit you are using are incompatible, could you try instead using v0.4.2 and let me know if that fixes your issue.

To give you an idea of how fast the adapter API is changing, I last released a build 19 days ago, to fix issues with the then current API, those changes are already out of date and the Svelte team seem to have changed the way that want to do things yet again.

yarbsemaj commented 2 years ago

You may also want to rebase your project onto the latest svelte kit build 1.0.0-next.301 and use the latest adapter version

ivands commented 2 years ago

Upgrading to 1.0.0-next.301 doesn't help. The build folder doesn't have an index.js file inside.

ivands commented 2 years ago

Upgrading the adapter to 0.6.0 fixed the issue tho. Thanks for the work. I'll be trying out this package in the coming days.

yarbsemaj commented 2 years ago

Hi @ivands That is expected behaviour as the file is removed at the end of the build process.

Im glad updating fixed your issue however :)