Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
tree: 40b4f4e54e
Fetching contributors…

Cannot retrieve contributors at this time

16 lines (12 sloc) 0.867 kb

feature: calc() status: caution tags: none kind: css polyfillurls:

Internet Explorer, Chrome and Firefox are the only supporting browsers, which makes using calc() in production tedious given the impact it can have on layout and the consequent breaking of your design on unsupported browsers. We encourage you to use it for experimentation and always use a fallback declaration, so it doesn't break browsers which don't support it.

For now, calc() must always be used after a fallback declaration, so it doesn't break browsers which don't support it.

width: 500px; /** older browsers **/
width: -webkit-calc(50% - 20px); /** Chrome / Safari **/
width: -moz-calc(50% - 20px); /** Mozilla Firefox **/
width: -o-calc(50% - 20px); /** could be calc(), no idea about Opera's plans **/
width: calc(50% - 20px); /** IE and future other browsers **/
Jump to Line
Something went wrong with that request. Please try again.