TL;DR – I came up with a very simple solution to handle WebSockets in Django apps. You just install django-websocket-request, run a script and you have WebSockets for your Django app. The cool thing is that this solution makes Django believe its getting a (somewhat) normal HTTP request so you can reuse almost all of you… Continue reading The easiest way to add WebSockets to Django
Tag: json
Auth with JSON Web Tokens
When it comes to implementing authentication on web apps, one solution you’ll definitely hear about first are cookies. Cookie-based authentication uses a server side cookies to authenticate the user on every request. This means that you’ll need to keep a session store, whether it’s on a database or on something like Redis. A solution you’ll… Continue reading Auth with JSON Web Tokens
Scraper and Web API for The News
I recently found out about http://thenews.im thanks to @gcollazo. The News is a pretty cool project by ahmetsulek that brings together under one same site LayerVault’s Designer News and Y Combinator’s Hacker News. I decided to take advantage of having all those posts from two different sources together and built a scraper for it with Node.js. Once I had all the posts stored… Continue reading Scraper and Web API for The News