leemunroe/responsive-html-email-template

Question: why are 'max-width' and 'width' equal on .container?

Closed this issue · 1 comments

I understand the max-width, but doesn't also setting a fixed width (to an equal pixel value) make the e-mail effectively fixed-width? Or is this some kind of workaround/hack?

/* Set a max-width, and make it display as block so it will automatically stretch  
to that width, but will also shrink down on a phone or something */
      .container {
        ...
        /* makes it centered */
        max-width: 580px;
        width: 580px; 
      }

In the smashingmag article you do use a percentage value;

.container {
  max-width: 600px;
  width: 100%;
}

Definitely a hack, but I forget why exactly. Likely to do with a version fo Outlook. Curious if you run into this issue or not.