2
votes
1answer
113 views

Designing javascript chart library

I started coding a chart library on top of d3js: My chart library. I read Javascript API reusability and Towards reusable charts. However, I am NOT really following the suggestions because I am not ...
13
votes
5answers
538 views

In API design, when to use/avoid ad hoc polymorphism?

Sue is designing a JavaScript library, Magician.js. Its linchpin is a function which pulls a Rabbit out of the argument passed. She knows its users may want to pull a rabbit out of a String, a ...
33
votes
3answers
5k views

What's so bad about the DOM?

I keep hearing people (Crockford in particular) saying the DOM is a terrible API, but not really justifying this statement. Apart from cross-browser inconsistencies, what are some reasons why the DOM ...
3
votes
2answers
403 views

Strategy for designing a plugin API

I am working on an application for which a rich plugin API is crucial. What is the best process for creating an API that is intuitive and easy to learn?