0
votes
1answer
80 views

Which approach would lead to an API that is easier to use?

I'm writing a JavaScript API and for a particular case, I'm wondering which approach is the sexiest. Let's take an example: writing a VideoPlayer, I add a getCurrentTime method which gives the elapsed ...
0
votes
1answer
201 views

Should I use my own public API on my site (via JS)?

First of all, this question is far more different other 'public api questions' like this: Should a website use its own public API?, second, sorry for my English. You can find the question summarized ...
0
votes
1answer
157 views

Best practice for storing information from a php script for future use

My employer uses forms to help people search for products. The product lists can change from time to time and the forms need to be updated again. The product information can be accessed through a ...
0
votes
2answers
85 views

How to manage potentially outdated data from WikiMedia API

I am writing a web application that pulls small parts of articles from Wikipedia and presents them to users. I do not wish to delete entries of the articles because I do not want to be sending a ...
0
votes
1answer
100 views

Technique to deal with occasionally blocking json api?

I have a web app that occasionally (after some idleness) will block a very simple request for small chunks of data (30~50 kb) up to 20 or so seconds. Assuming I can't refactor or modify the API, is ...
6
votes
4answers
685 views

Building a web application that is almost completely rendered by Javascript, while back end only delivers Json. Do or don't?

As a programmer, and taking into account the overall "funness" of the process, I'm tempted to start a project in Sinatra where the back end's sole concern is the logic, and returning a Json API, and ...
13
votes
5answers
514 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 ...
12
votes
4answers
636 views

Using natural language grammar in fluent API

I'm tinkering with a query abstraction over WebSQL/Phonegap Database API, and I find myself both drawn to, and doubtful of, defining a fluent API that mimics the use of natural English language ...
0
votes
2answers
171 views

Encapsulate external JavaScript library

I am about to develop a ASP.NET MVC 4 project that will make use of maps. Our company has it's own map API which is very basic at the moment, but is intended to be further developed in future to match ...
2
votes
1answer
271 views

HG: fork web app project to separate API code from app code [closed]

I have a web app thats been in active development for about 8 months now and its becoming apparent that the project has a need to maintain a separation between app specific code and our OO Javascript ...
3
votes
2answers
170 views

For a Javascript library, what is the best or standard way to support extensibility

Specifically, I want to support "plugins" that modify the behavior of parts of the library. I couldn't find much information on the web about this subject. But here are my ideas for how a library ...
2
votes
1answer
250 views

How do I mashup Google Maps with geolocated photos from one or more social networks? [closed]

I'm working on a proof of concept for a project, and I need to pin random photos to a Google Map. These photos can come from another social network, but need to be non-porn. I've done some research ...
32
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 ...
1
vote
2answers
220 views

Drawbacks to entirely Ajax driven CMS

I'll try to keep this question as specific as possible.. I'm about to start building an API for an upcoming project. I'm currently thinking PHP/Symfony2. It will be a farily simple HTTP-based api for ...
3
votes
2answers
390 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?