Questions tagged [pym.js]

Pym.js is a javascript libarary for embedding and resizing an iframes responsively (width and height) within their parent containers. It also bypasses the usual cross-domain issues.

About

Using iframes in a responsive page can be frustrating. It’s easy enough to make an iframe’s width span 100% of its container, but sizing its height is tricky — especially if the content of the iframe changes height depending on page width (for example, because of text wrapping or media queries) or events within the iframe.

Pym.js embeds and resizes an iframe responsively (width and height) within its parent container. It also bypasses the usual cross-domain issues.

Use case: The NPR Visuals team uses Pym.js to embed small custom bits of code (charts, maps, etc.) inside our CMS without CSS or JavaScript conflicts.

Links

3 questions
2
votes
2 answers

Executing code at the end of angular initialization, and ngCloak display

I have a webpage written in angular with an ngCloak directive. It is loaded in a dynamically sized iframe with pym.js. The trouble is that the page does not appear unless I resize the browser or trigger a resize event, or call pymChild.sendHeight()…
Justin Dearing
  • 14,270
  • 22
  • 88
  • 161
0
votes
1 answer

Using pym.js with Github Pages won't work

I'm setting up a Github Pages web page. I want to put some interactive charts on this page. I've made each chart in its own separate HTML file and want to use pym.js to put them on the Github Pages web page. On the .md page I have something like…
Username
  • 3,463
  • 11
  • 68
  • 111
0
votes
2 answers

How to use pym.js

I'm a Java programmer, so I'm not just coming in here (completely)n00b-like. My boss just asked me to work on a project and after speaking with an engineer for the client company, I need to create a responsive iframe using pym.js. Problem is, I've…
David Cash
  • 29
  • 6