{"id":25282836,"url":"https://github.com/paulsenon/poc-node-sharp-image-server-playground","last_synced_at":"2026-04-27T17:33:44.465Z","repository":{"id":224048030,"uuid":"762255863","full_name":"PaulSenon/poc-node-sharp-image-server-playground","owner":"PaulSenon","description":"Just a quick poc to experiement with sharp lib and how to tweak options to make it performant.","archived":false,"fork":false,"pushed_at":"2024-02-23T12:12:15.000Z","size":1125,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-06-28T22:50:32.693Z","etag":null,"topics":["image-processing","nodejs","sharp","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/PaulSenon.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}},"created_at":"2024-02-23T11:59:32.000Z","updated_at":"2024-06-02T20:35:13.000Z","dependencies_parsed_at":"2024-02-23T13:26:58.594Z","dependency_job_id":"a06f32c8-bf7d-4c43-b5b3-0d22f2255c39","html_url":"https://github.com/PaulSenon/poc-node-sharp-image-server-playground","commit_stats":null,"previous_names":["paulsenon/poc-node-sharp-image-server-playground"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/PaulSenon/poc-node-sharp-image-server-playground","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulSenon%2Fpoc-node-sharp-image-server-playground","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulSenon%2Fpoc-node-sharp-image-server-playground/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulSenon%2Fpoc-node-sharp-image-server-playground/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulSenon%2Fpoc-node-sharp-image-server-playground/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PaulSenon","download_url":"https://codeload.github.com/PaulSenon/poc-node-sharp-image-server-playground/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PaulSenon%2Fpoc-node-sharp-image-server-playground/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32348048,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-27T17:12:42.749Z","status":"ssl_error","status_checked_at":"2026-04-27T17:12:41.658Z","response_time":128,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["image-processing","nodejs","sharp","typescript"],"created_at":"2025-02-12T19:52:05.548Z","updated_at":"2026-04-27T17:33:44.448Z","avatar_url":"https://github.com/PaulSenon.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# POC with express and sharp\n\nThis is a POC to test the sharp library to resize images in a express server.\nThis is meant to be a playground to test the sharp library and other things in order to build a lambda function to resize images that is efficient and fast.\n\nFeatures:\n\n* Typescript\n* swc\n* prettier\n* eslint\n* dockerized\n* Sharp\n* Zod validation\n* Express\n\n## Installation\n\n### Requirements\n\n* docker\n* docker compose\n* make\n\n### Steps\n\n1. Clone the repository\n2. Run `make install` to install the dependencies\n3. Run `make dev` to start the project in dev\n4. Go to `http://localhost:8080` (or any port configured in .env `DEV_PORT`) to see the project running\n\n### Endpoint usage\n\n* `GET /image` - Resize an image\n  * `src`: string **[REQUIRED]** - image name from folder `images` (e.g. `image-1.jpg`)\n  * `w`: number - target width in pixel (e.g. `200`) (you can use `w` or `h` or both, but at least one is required)\n  * `h`: number - target height in pixel (e.g. `200`) (you can use `w` or `h` or both, but at least one is required)\n  * `fit`: cover | contain | fill | inside | outside - how to fit the image when constraining both width and height (e.g. `cover`) (default: `cover`)\n  * `type`: avif | jpg | png | webp | matchSource | auto - output image type (e.g. `webp`) (default: `auto`)\n  * `q`: number 0-100 - quality of the output image (for lossy types only) (e.g. `80`) (default: `75`)\n\n### Tools\n\n* There is a `debug.html` file you can open in your browser. It is meant to test cache policies loading a `\u003cimg/\u003e` tag in the DOM.\n\n## Commands\n\n* `make install` - Install the dependencies\n* `make dev` - Start the project in dev mode\n* `make clean` - Clean everything (docker images, volumes, node_modules, dist, etc.)\n* `make quality` - Run the quality checks (eslint, prettier etc.)\n* `make bash` - Open a bash inside the container (to install new dependencies, or run any other command)\n\n## License\n\nfeel free to use it as you want\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaulsenon%2Fpoc-node-sharp-image-server-playground","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpaulsenon%2Fpoc-node-sharp-image-server-playground","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpaulsenon%2Fpoc-node-sharp-image-server-playground/lists"}