Code Monkey home page Code Monkey logo

favicon-proxy's Introduction

Favicon proxy

This service allows to load favicon for any website with CORS headers. Usage: GET /domain.com
It doesn't convert the icon to PNG format, just adds CORS headers to enable favicon display on any website.
Ready for Heroku.

Example

https://services.keeweb.info/favicon/apple.com

Alternatives

Usage

Please don't use my app instance if you need frequent requests: deploy your own one.

License

MIT

favicon-proxy's People

Contributors

jsdelivrbot avatar umlx5h avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

favicon-proxy's Issues

Support for link rel="icon" and .png icons

Hello,

I noticed Keeweb is using this service to download favicons. However it does not download all favicons.

For example: GET https://favicon-antelle.rhcloud.com/www.dailymotion.com
Expected result: the server sends the favicon of dailymotion.com
Actual result: server sends a 404 status

https://www.google.com/s2/favicons?domain=www.dailymotion.com works well.

Two possible fixes could be:

  • get PNG icon if ICO is not found
  • if PNG icon is not found, follow http redirections (like Location header and meta http-equiv="REFRESH") until no other redirection, then follow link rel="icon" if provided

Configure throttling thresholds from env

The recent addition of throttling makes a self-hosted instance block trusted sources, so I needed to manually edit the file to override the settings:

  • IP_THROTTLING_MS = 0;
  • IP_THROTTLING_AGGRESSIVE_LOCKDOWN_DETECTION_THRESHOLD = 0;

Please make these configurable from env. The defaults can be your current values if the env values are empty.

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.