Category: JavaScript

WebSockets and Android

WebSockets and Android

I didn’t know that the default browser installed on Android is called Webview. I haven’t created any native Android app ever. But I wanted my web app to run on Android using Websockets. Unfortunately, websockets are not implemented in Android Webview. In modern browsers, HTML5 provides a websocket API:  ws = new WebSocket(‘ws://’ + host […] Sigue leyendo

Fluent API for test doubles

Fluent API for test doubles

There are several good frameworks out there to create test doubles with JavaScript. Jasmine  and Sinon provide test spies and stubs. JsMockito looks good too. However, creating your own API for test stubs is very easy. I’ve created mine as an exercise. It’s a very naive implementation but it works. See the code:  describe(“a fluent […] Sigue leyendo

London Tester Gathering Workshops

London Tester Gathering Workshops

Next week, I’ll be taking part in the London Tester Gathering Workshops at SkillsMatter. I’ll be giving a 4 hours workshop on JavaScript aimed at software testers on Thursday. Inspired by the workshop, I am working on a JavaScript manual for testers (JavaScript4Testers) that will be available soon. The manual will serve as a guide […] Sigue leyendo

A week in the UK

A week in the UK

Talking at SkillsMatter Last week was very intense indeed. I gave my first talk at Skills Matter (video here). BDD for RIAs with JavaScript – Skills Matter from Carlos Ble I must say I am not content with my talk because my English was rubbish but on the other hand I am glad that it […] Sigue leyendo

RIAs: the domain is not in the server side

RIAs: the domain is not in the server side

Rich internet applications bring a powerful user experience. But in order to achieve that, they must be written totally different from traditional webs. The paradigm is totally different and so the architecture.  There is no “server side” as such. In some cases it’s just a deployment site, where you have to browse in order to […] Continue reading

This was SpainJS 2013

This was SpainJS 2013

The 2nd edition of the SpainJS conference was held in Madrid last week. On Thursday there were workshops the whole day. Talks and networking happened on Friday and Saturday. I attended to the workshops and learned a lot in the first one, about memory leaks hunting with Gonzalo Ruiz de Villa (@gruizdevilla). What I remember the […] Continue reading

The sticky scroll bar inside the draggable

The sticky scroll bar inside the draggable

jQuery UI draggable is so cool! However, if the draggable element (or any of its children) contains a scroll bar, clicking on it will result in the mouse pointer stuck on the whole draggable element forever. To avoid that, use the “cancel” option:   $(’#theDraggable’).draggable({ cancel: "input, textarea, .someClass" });     And it will […] Continue reading