[Request]: Moving withSSRContext out of the aws-amplify pakage
See original GitHub issueIs your feature request related to a problem? Please describe.
I am using Serverless framework to deploy Nextjs. They deploy single lambda@edge for all server side rendering pages and single lambda@edge for all api. Each lambda has limitation of 50MB storage zipped. import Amplify, { withSSRContext } from 'aws-amplify
Adds 1.3 MB per SSR page or per SSR path. So at max I can deploy only 40 SSR pages or 40 API not including other packages. It looks like a lot but gets over quickly.
I added single api and size of lambda@edge was 1.3 Mb. I added 3 api paths and size of lambda@edge became 4Mb.
All all Api’s I am checking if user is logged in or not.
Describe the solution you’d like
I use
import Amplify from '@aws-amplify/core
.
I was hoping to get something like
import { withSSRContext } from '@aws-amplify/ssr'
Describe alternatives you’ve considered Give up on SSR/Nextjs and go back to CSR/React.
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (4 by maintainers)
Top GitHub Comments
I thought this was a very nice & minimal example. As for CDK tutorials, I’d recommend following along with CDK Workshop.
I have no immediately-obvious advice on ensuring a smooth NextJS + Fargate + AmplifyJS experience: I think it’ll be pretty smooth even without the advice 😉 but if you do encounter difficulty, please don’t hesitate to file an issue or reach out in our Discord.
That’s an awesome announcement! Would definitely be interesting to explore. I’m eager to test out the
Deno
runtime on AWS Lambda functions.This issue has been automatically locked since there hasn’t been any recent activity after it was closed. Please open a new issue for related bugs.
Looking for a help forum? We recommend joining the Amplify Community Discord server
*-help
channels or Discussions for those types of questions.