May 2016


I’ve been contributing to, and recently been made a collaborator of Bliss.js, a modern approach to cross browser Javascript. View on GitHub

I would like to introduce you to a really interesting “minimal” library for working with vanilla Javascript Bliss.js. I went from fan, to contributor and now collaborator on this project. I urge you to check this out and think about

what parts of jQuery do you really use?

In my opinion, the days are gone when you need a monolith library such as jQuery to save you from cross browser support hell. Using document.querySelector in conjunction with Bliss.js will accomplish most day to day tasks on the DOM. And oh yeah, it’s 10k.

The library includes a $ wrapper for document.querySelector similar to jQuery, async methods, utility methods for working with Arrays and Objects and more.

For example Bliss’s ajax fetch method using promises.

$.fetch("/api/create", {
  method: "POST",
  responseType: "json"
  console.error(error, "code: " + error.status);

But the thing that really excites me about the way that Bliss is structured, is that it extends a _ object on all DOM Nodes.

This gives you all the convinces of Prototype extension that was super popular a while ago but has fallen out of favor because of (unpredictably of native Javascript objects)[].

With the _ object added to DOM Nodes you can do things like the following. All three of the following work the same. Giving you flexibility with using Bliss.

subject = $.properties(subject, props)
subject =
subject = subject._.set({properties: props})

If adding objects to DOM Nodes is not for you, there is even a “bliss shy” download which does not add the _ object.

This is just a taste, but checkout the docs for yourself,