Skip to content

LuckyCrack/pixel-vh-vw-converter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Pixel to VH/VW Converter

This tool will allow you to easily convert values from Pixel units to VH/VW units and viceversa.

What makes this tool different?

What makes this tool a bit different is that you don't need to go and find your window viewport size everytime you want to convert an element cause javascript does that for you.

How to use the tool ??

Let's say you want to make your element responsive. One of the things you would do is to changes the pixels to a vw or vh units. Assuming the element is 150px. Then you would open the tool and resize the window accordingly and then type the pixels ratio.

The element that I want to make responsive is the two selection box. u

The element that I want to convert has 150px

After we convert the element we get 32.96vh

Changing the pixel to vh

Our element is now responsive

Also this tool is dynamic. Which means that you could resize it without the need to refresh your browser.

Pixel PX to VH Viewport conversion

Pixel PX to VW Viewport conversion

VW Viewport to Pixel PX conversion

VH Viewport to Pixel PX conversion