-
Notifications
You must be signed in to change notification settings - Fork 16
/
react-helmet.react.txt
48 lines (37 loc) · 3.12 KB
/
react-helmet.react.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
REACT-HELMET
VERSION ==> #4.0.0
/=+===============================+=\
/ : : \
)==: CLIENT :==(
\ :_______________________________: /
\=+===============================+=/
<Helmet/> #Modifies current <head> when rendered:
# - can be placed anywhere in the DOM tree.
# - tag conflicts:
# - innermost override outermost
# - in same component: merged
#OBJ are HTML attributes
htmlAttributes=OBJ #
title=STR #
titleTemplate=STR #'%s' is replaced by STR from title=STR
defaultTitle=STR #Used when titleTemplate used with %s, but not title=STR specified
titleAttributes=OBJ #
base=OBJ #
meta=OBJ_ARR #
link=OBJ_ARR #
script=OBJ_ARR #Including OBJ.innerHTML STR
noscript=OBJ_ARR #
style=OBJ_ARR #Including OBJ.cssText STR
onChangeClientState(HEAD) #On props change
/=+===============================+=\
/ : : \
)==: SERVER :==(
\ :_______________________________: /
\=+===============================+=/
HELMET.rewind()->HEAD #Must be done after REACTDOM.renderTo*()
HELMET.peek()->HEAD #Can be done at any point. Only for testing.
HEAD.htmlAttributes|title|base|
meta|link|script|noscript|style.
toString|Component()->'HTML'|RTYPE#