{"id":19400830,"url":"https://github.com/krishanthisera/aws-edge-functions","last_synced_at":"2026-05-16T03:38:30.483Z","repository":{"id":182735141,"uuid":"668937213","full_name":"krishanthisera/aws-edge-functions","owner":"krishanthisera","description":"This repository is a Terraform sub-module designed for use with the AWS Static Hosting module. Its primary purpose is to deploy Lambda@Edge functions for prerender integration with CloudFront. Enhance page loading speed and search engine indexing for SPAs and dynamic web applications.","archived":false,"fork":false,"pushed_at":"2023-08-24T07:29:20.000Z","size":117,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-01-07T11:50:03.800Z","etag":null,"topics":["cdn","cloudfront","edge-computing","iac","lambda-functions","prerender","s3","spacelift","static-site","terraform","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/krishanthisera.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-07-21T00:52:57.000Z","updated_at":"2023-11-18T07:41:31.000Z","dependencies_parsed_at":"2025-01-07T11:49:28.709Z","dependency_job_id":"307dec1e-28d9-44ec-a36e-8c5ed8edb0e1","html_url":"https://github.com/krishanthisera/aws-edge-functions","commit_stats":null,"previous_names":["krishanthisera/aws-edge-functions"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krishanthisera%2Faws-edge-functions","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krishanthisera%2Faws-edge-functions/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krishanthisera%2Faws-edge-functions/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krishanthisera%2Faws-edge-functions/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/krishanthisera","download_url":"https://codeload.github.com/krishanthisera/aws-edge-functions/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240576481,"owners_count":19823293,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cdn","cloudfront","edge-computing","iac","lambda-functions","prerender","s3","spacelift","static-site","terraform","typescript"],"created_at":"2024-11-10T11:16:02.957Z","updated_at":"2026-05-16T03:38:25.464Z","avatar_url":"https://github.com/krishanthisera.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AWS Edge Functions - Terraform Sub-Module\n\nThis repository serves as a Terraform sub-module designed for use with the AWS Static Hosting module. The primary purpose of this module is to deploy a set of Lambda@Edge functions that provide prerender integration for CloudFront. This enables faster page loading and improved search engine indexing for Single Page Applications (SPAs) and other dynamic web applications.\n\n## Usage\n\nTo use this module in your Terraform configuration, simply add the following code:\n\n```hcl\nmodule \"edge-functions\" {\n  source = \"github.com/krishanthisera/aws-edge-functions.git\"\n}\n```\n\nAfter adding the module, run `terraform init` to initialize your configuration.\n\n## Technologies Used\n\nThis module is built using the following technologies and tools:\n\n- Terraform: Infrastructure as Code (IaC) tool used to manage AWS resources.\n- TypeScript: Language used to write the Lambda@Edge functions.\n- turbo-repo: A tool used for repository management and monorepo setups.\n- esbuild: Used to bundle the TypeScript code and set environment variables during the build process.\n\n## How to Use as a Terraform Module\n\nTo use this repository as a Terraform module, you can refer to the example provided in the [AWS Static Hosting repository](https://github.com/krishanthisera/aws-static-hosting/tree/main). It showcases how to integrate this module to enable prerendering with CloudFront.\n\n## Prerender Integration\n\nThe deployed Lambda@Edge functions work in conjunction with CloudFront to perform prerendering. This means that when a request is made to CloudFront for a page of your SPA (from a crawler), the Lambda@Edge functions will leverage prerender service to generate a prerendered version of the page and serve it to the user. This leads to improved page loading times and better SEO performance.\n\n## Handling Environment Variables\n\nAs you are not able to set environment variables at runtime for the Lambda@Edge functions, during the build process, esbuild is used to configure the necessary environment variables and bundle them into the build artifacts.\n\n## How to Contribute\n\nContributions to this project are welcome! If you have any bug reports, feature requests, or improvements to suggest, you can do so by creating a pull request or opening an issue. Your feedback is highly valuable to us, and we appreciate any contributions made to enhance this module.\n\n## Contact\n\nIf you have any questions or need further assistance, you can contact the project maintainer by creating an issue in this repository.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrishanthisera%2Faws-edge-functions","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkrishanthisera%2Faws-edge-functions","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrishanthisera%2Faws-edge-functions/lists"}