You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Carlos Alba edited this page Nov 21, 2020
·
1 revision
ptpx
This is a utility that helps you pull percentages of pixels
for example 0.1% or 100px is 10px this function basically just returns
the percentage of pixels. This was created to use with iframes
since the iframe API does not support percentage based heights and widths.
NOTE!: THIS WAS USED AS A HACKY but RELIABLE WORKAROUND for setting responsive (percentage based)
heights for iframes and should not be used in any context where you could merely use percentages or
responsive units for the same job.