Documentation: https://antonbobrov.github.io/rotate-html/
npm install rotate-html
<script src="https://cdn.jsdelivr.net/npm/rotate-html/dist/cdn/index.min.js"></script>
<div id="rotate-html">This is a template node element.</div>
import rotateHtml from 'rotate-html';
rotateHtml({
selector: '#rotate-html'
});
Option | Type | Default | Description |
---|---|---|---|
selector | string|HTMLElement | #html-rotate | The selector of the element. |
rotate | 90|-90 | -90 | Rotation angle. |
updateOnResize | boolean | true | If you need to update the sizes of the element on resize. |