Author : Cyril Pereira
Put a HTML node in fullscreen fitted homothetically inside the browser
GitHub : https://github.com/funkymed/fullscreen
Image : http://medcg.free.fr/tmp/fullscreen/index.html
yarn add funkymed-fullscreen --save
yarn build
yarn start
import $ from "jquery";
import '../dist/Fullscreen'
componentDidMount()
{
$('.imgresized').Fullscreen({fade:3000});
}
render()
{
return (
<div>
<img className="imgresized" src="images/image7.jpg" />
</div>
);
}
Just do this
$('img').Fullscreen();
$('img').Fullscreen({transition:'ease-in-out',speed:0});
transition : ease-in, ease-out, ease-in-out
speed : time in second
$('img').Fullscreen({fade:3000});
fade : time in millisecond for the fade after load img
if you need use something else than image, you will need to set the size
just add width and height to the object option
$('img').Fullscreen({width:1280,height:720});