Skip to content

Conversation

@harajune
Copy link

@harajune harajune commented Jun 2, 2025

What is this

The hono vite plugin for Lambda / Lambda Edge Deployment.
The plugin creates the packaged JS file of HonoX that can be deployed to AWS Lambda Edge.

Changes

  • Updated package.json to include Lambda / Lambda Edge adapter types and imports.
  • Added aws-lambda / lambda-edge ada[ter
  • Added tests for the Lambda Edge adapter to ensure correct project building and output validation.

Notes

I just found that this PR is a duplicate of #268 .
However, this PR has the support for the lambda edge, too.

Jun Harada and others added 7 commits May 21, 2025 10:36
- Updated package.json to include Lambda Edge adapter types and imports.
- Added tests for the Lambda Edge adapter to ensure correct project building and output validation.
- Added `copyPublicDir` option to BuildOptions for controlling public directory copying during builds.
- Updated default options to enable `copyPublicDir` by default.
- Modified LambdaEdgeBuildOptions to include a `staticRoot` option and set `copyPublicDir` to false for Lambda Edge builds.
- Introduced AWS Lambda adapter with `lambdaBuildPlugin`
- Added `aws-lambda` export in package.json for types and imports
- Extended `BuildOptions` with new `sourcemap` option
- Updated test suite to include AWS Lambda adapter build tests
@changeset-bot
Copy link

changeset-bot bot commented Jun 2, 2025

🦋 Changeset detected

Latest commit: ae9189a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@hono/vite-build Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@yusukebe
Copy link
Member

yusukebe commented Jun 4, 2025

HI @harajune

This PR also supports Lambda Edge, but supporting Lambda is duplicated by #268. We want to give priority to PRs for the earliest created. We will wait for a while for an update to #268.

@harajune
Copy link
Author

harajune commented Jun 4, 2025

Of course, it is ok.

@yusukebe
Copy link
Member

Hi @harajune !

As @Mushus commented, we will go with this PR about supporting Lambda / Lambda Edge instead of #268.

@Mushus, can you review this? I'll also do it later.

@harajune
Copy link
Author

Oh! Very happy to hear that!

Any feedback is welcome.
I will also check the comment on #268 and consider improvements.

@hadson172
Copy link

Any updates on the topic ? Would be nice to have vite supported aws with hono

Copy link
Member

@yusukebe yusukebe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@harajune Can you update the README?

@danielsharvey
Copy link

@harajune Any chance of looking at this? (and updating README)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants