File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -19,6 +19,13 @@ Contributor License Agreement at https://developers.google.com/open-source/cla/i
19
19
Custom C++-specific elements
20
20
----------------------------
21
21
22
+ Some of these elements define a ` checkInvariants() ` method, so you can run:
23
+
24
+ document.querySelectorAll('*').array().forEach(
25
+ function(node){ if (node.checkInvariants) node.checkInvariants(); });
26
+
27
+ to see if you've gotten anything wrong.
28
+
22
29
### ` <cxx-include href="other.html"> `
23
30
24
31
This one isn't really C++-specific: it allows partitioning a main document
Original file line number Diff line number Diff line change @@ -20,6 +20,12 @@ limitations under the License.
20
20
21
21
applyAuthorStyles : true ,
22
22
23
+ checkInvariants : function ( ) {
24
+ if ( ! this . id ) {
25
+ console . error ( this , 'is missing an id.' ) ;
26
+ }
27
+ } ,
28
+
23
29
update_sec_nums : function ( sec_num ) {
24
30
this . sec_num = sec_num + '' ;
25
31
var child_index = 1 ;
You can’t perform that action at this time.
0 commit comments