From 07e20726923f29d2a323779b08583baa4b7fb526 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Paul=20O=E2=80=99Shannessy?= Date: Mon, 26 Aug 2013 09:21:50 -0700 Subject: [PATCH] Support props for elements. `content`, `httpEquiv`, `charSet` are all needed. We're currently working around this in `react-page`. `content` is the risky one here since we previously supporting using `content` to set the text content. We removed support for that in e9980412296b6469f39605f48ea527776d7ac718 so the risk is minimal, there just might be some lingering old code. Fixes #292 Test Plan: Visit `data:text/html,` ``` var m = document.querySelector('meta'); m.httpEquiv; // Content-Type m.httpEquiv = 'foo'; m.httpEquiv; // foo m.charset; // undefined m.charSet; // undefined m.getAttribute('charset'); // utf-8 m.setAttribute('charset', 'bar'); m.getAttribute('charset'); // bar m.content; // text/html; charset=utf-8 m.content = 'baz'; m.content; // baz ``` --- src/dom/DefaultDOMPropertyConfig.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/dom/DefaultDOMPropertyConfig.js b/src/dom/DefaultDOMPropertyConfig.js index abddcb7438..b068cc45dd 100644 --- a/src/dom/DefaultDOMPropertyConfig.js +++ b/src/dom/DefaultDOMPropertyConfig.js @@ -45,9 +45,11 @@ var DefaultDOMPropertyConfig = { autoPlay: HAS_BOOLEAN_VALUE, cellPadding: null, cellSpacing: null, + charSet: MUST_USE_ATTRIBUTE, checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, className: MUST_USE_PROPERTY, colSpan: null, + content: null, contentEditable: null, contextMenu: MUST_USE_ATTRIBUTE, controls: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE, @@ -62,6 +64,7 @@ var DefaultDOMPropertyConfig = { hidden: MUST_USE_ATTRIBUTE | HAS_BOOLEAN_VALUE, href: null, htmlFor: null, + httpEquiv: null, icon: null, id: MUST_USE_PROPERTY, label: null,