Giter Club home page Giter Club logo

img-resizer's Introduction

Image Resizer

Image Resizer Cloudflare Worker, returns base64 encoded image data.

Feel free to use this API in your projects; please include pertinent information in the User-Agent header, such as project name or a URL.

Supported Image Dimensions

  • This worker also accepts dimensions for width and height within the formdata.
  • These dimensions should be powers of 2, ranging from 16px to 1024px. If no dimensions are specified, it will default to 128, invalid dimensions will throw 400.

Usage

/resize - POST

  • image - The image to be resized (required)
  • width - The width of the image (optional)
  • height - The height of the image (optional)

Setup

  • Clone repo git clone https://github.com/wanderer-moe/img-resizer
  • Modify wrangler.toml to your needs
  • Deploy w/ wrangler deploy

Run locally

  • wrangler dev

Deploy

  • wrangler deploy

License

This repository is licensed under the GNU Affero General Public License v3.0 license โ€” You must state all significant changes made to the original software, make the source code available to the public with credit to the original author, original source, and use the same license.

img-resizer's People

Contributors

dromzeh avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.