File tree Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Expand file tree Collapse file tree 2 files changed +16
-0
lines changed Original file line number Diff line number Diff line change 56
56
< body >
57
57
< div id ="app "> Loading ...</ div >
58
58
< script >
59
+ // Set html "lang" attribute based on URL
60
+ var lang = location . hash . match ( / # \/ ( d e - d e | e s | r u - r u | z h - c n ) \/ / ) ;
61
+
62
+ if ( lang ) {
63
+ document . documentElement . setAttribute ( 'lang' , lang [ 1 ] ) ;
64
+ }
65
+
66
+ // Docsify configuration
59
67
window . $docsify = {
60
68
alias : {
61
69
'.*?/awesome' :
Original file line number Diff line number Diff line change 26
26
< body >
27
27
< div id ="app "> </ div >
28
28
< script >
29
+ // Set html "lang" attribute based on URL
30
+ var lang = location . hash . match ( / # \/ ( d e - d e | e s | r u - r u | z h - c n ) \/ / ) ;
31
+
32
+ if ( lang ) {
33
+ document . documentElement . setAttribute ( 'lang' , lang [ 1 ] ) ;
34
+ }
35
+
36
+ // Docsify configuration
29
37
window . $docsify = {
30
38
alias : {
31
39
'.*?/awesome' : 'https://raw.githubusercontent.com/docsifyjs/awesome-docsify/master/README.md' ,
You can’t perform that action at this time.
0 commit comments