Giter Club home page Giter Club logo

anchorme.js's Introduction

Anchorme.js

npm npm GitHub release license David David

Documentation

Tiny, fast, efficient, feature rich Javascript library to detect links / URLs / Emails in text and convert them to clickable HTML anchor links.

What's Included

  • Sensitivity: It's Highly sensitive with the least false positives.
    • It validates URLs and Emails against full IANA list
    • Validates port numbers (if present)
    • Validates IP octet numbers (if present)
  • Robustness:
    • Skips HTML, so it doesn't break your HTML if it had a URL as an attribute for an element.
    • Links with or without protocols.
    • Works with IPs, FTPs, Emails and files.
    • Can detect parenthesis and quotation marks as part of the URL or as a surrounding to the URL.
  • Fast: It's definitely fast! processing H.G. Wells The Time Machine novel with over 1500 URLs inserted at random places takes only 3.5 seconds.
  • Light Weight: Although it's a feature rich library with a full IANA list included, it's only 6KB when minified and gzipped.

Contributing

This project is written in Typescript and compiled to JavaScript.

Prerequisites:

  • Typescript installed globally
  • Jest installed globally (for testing)

How to contribute

  • Clone this repository
  • cd anchorme.js && npm install
  • ..
  • Add unit tests if needed
  • Run npm run test for testing
  • Run npm run build for building

License: The MIT License (MIT) - Copyright (c) 2017 Alex Corvi

anchorme.js's People

Contributors

alexcorvi avatar ali-saleem avatar azagniotov avatar chrisoelmueller avatar davidschlachter avatar faizanahemad avatar harryburns avatar ionogy avatar

Watchers

 avatar  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.