Skip to content

Instantly share code, notes, and snippets.

@dustinpoissant
Last active November 28, 2016 19:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dustinpoissant/7828a80d2899c57d92472b59675fc3fa to your computer and use it in GitHub Desktop.
Save dustinpoissant/7828a80d2899c57d92472b59675fc3fa to your computer and use it in GitHub Desktop.
Check if a CSS property/value is valid.
function validCSS(property, value){
var $el = $("<div></div>");
$el.css(property, value);
return ($el.css(property) == value);
}
function validCSS(a,b){var c=$("<div></div>");return c.css(a,b),c.css(a)==b}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment