GithubHelp home page GithubHelp logo

d3-tip-1's Introduction

d3.tip: Tooltips for d3.js Version 4, without ES6

Screenshot

See a live example.

Origins

While it hasn't been updated since 2015, the popular d3-tip code from Justin Palmer (Caged on github; http://github.com/Caged/d3-tip) has been widely used with d3js version 3. I was one of those users.

With the release of d3js version 4, the old d3-tip code no longer worked. Thanks to a fork from Constantin Gavrilete (cgav on github; https://github.com/cgav), the code was updated to work with d3js version 4. However, this new version from cgav used the JavaScript ES6 import statement, which is not widely supported in today's browsers.

I needed a version that was both D3js v4 and standard-browser compatible.

Using d3-tip with D3js v4, without ES6

The version of d3-tip in this repository is D3js v4 compatible. At the same time, it does not require ES6 support from your browser. This is accomplished with two basic changes.

  1. d3.functor is defined. This was defined in version 3 of D3, but disappeared in version 4. It gets redefined in this version of d3-tip.

  2. d3.tip is defined. This mimics the prior behavior of d3-tip, allowing you to use tooltips as documented in the original repository (https://github.com/Caged/d3-tip).

d3-tip-1's People

Contributors

davegotz avatar

Watchers

 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.