JSFiddle - React, Tailwind, and code Playground

HTML

<div class="bottle"></div><html>

CSS

.bottle {
            width: 200px;
            height: 200px;
            background-image: url(http://jsfiddle.net/img/logo.png);
            -webkit-transition: -webkit-transform 6s ease-out;
        }

JavaScript

var i = 1;
$('.bottle').on('click', function(e) {
    this.removeAttribute('style');
    var deg = 3000 + Math.round(Math.random() * 500);
    deg = ((-1) ^ i) * deg;

    var css = '-webkit-transform: rotate(' + deg + 'deg);';
    this.setAttribute('style', css);
    i++;
});