File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -931,6 +931,7 @@ function compile(
931
931
isrc = reader ( imports [ i ] ) ;
932
932
}
933
933
targ =
934
+ `/*___wenyan_import_${ imports [ i ] } _start___*/` +
934
935
mwrapper (
935
936
imports [ i ] ,
936
937
compile ( lang , isrc , {
@@ -941,7 +942,7 @@ function compile(
941
942
lib
942
943
} )
943
944
) +
944
- "/*=-=-=-=-=-=-=*/" +
945
+ `/*___wenyan_import_ ${ imports [ i ] } _end___*/` +
945
946
targ ;
946
947
}
947
948
Original file line number Diff line number Diff line change @@ -95,8 +95,10 @@ function main() {
95
95
var showcode = code ;
96
96
97
97
if ( hidestd . checked ) {
98
- var s = showcode . split ( "/*=-=-=-=-=-=-=*/" ) ;
99
- showcode = s [ s . length - 1 ] ;
98
+ showcode = showcode . replace (
99
+ / \/ \* _ _ _ w e n y a n _ i m p o r t _ ( [ \s \S ] + ?) _ s t a r t _ _ _ \* \/ ( [ \s \S ] * ?) \/ \* _ _ _ w e n y a n _ i m p o r t _ ( [ \s \S ] + ?) _ e n d _ _ _ \* \/ / g,
100
+ "/* module $1 is hidden */\n"
101
+ ) ;
100
102
}
101
103
102
104
document . getElementById ( "js" ) . innerText = js_beautify ( showcode ) ;
You can’t perform that action at this time.
0 commit comments