JSFiddle - React, Tailwind, and code Playground

by ipan ridha

HTML

<!DOCTYPE html>
<html>
<head>
<link rel="stylesheet" href="style.css">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.4/jquery.min.js"></script>
<script>
$(document).ready(function(){
    $('.zoom').hover(function() {
        $(this).addClass('transisi');
    }, function() {
        $(this).removeClass('transisi');
    });
});  
</script>
</head>
<body>
<center>
<h1> menambah efek zoom pada image </h1>
<img src="https://res.cloudinary.com/hpiynhbhq/image/upload/v1516775950/lagjfo06fpfnpxfxylff.png" class="zoom"/>
</center>
</body>
</html>

CSS

img.zoom {
    width: 300px;
    height: 175px;
    -webkit-transition: all .2s ease-in-out;
    -moz-transition: all .2s ease-in-out;  
}
.transisi {
    -webkit-transform: scale(1.8); 
    -moz-transform: scale(1.8);
    -o-transform: scale(1.8);
    transform: scale(1.8);
}