File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
src-commons-ui/float-pane Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,6 @@ export class SnippetView extends React.Component<Props, State> {
4949 }
5050}
5151
52-
5352const regexPremeable = / ^ \s * < ( \? | ! ) ( [ a - z A - Z ] + ) ? \s * / i
5453const regexLSPPrefix = / ^ \( ( m e t h o d | p r o p e r t y | p a r a m e t e r | a l i a s ) \) \W /
5554
@@ -83,8 +82,10 @@ export async function getSnippetHtml(
8382 snippets . forEach ( ( snippet ) => {
8483 const preElem = document . createElement ( "pre" )
8584 const codeElem = document . createElement ( "code" )
86- snippet = snippet . replace ( regexPremeable , "" ) // remove any preamble from the line
87- codeElem . innerText = snippet . replace ( regexLSPPrefix , "" ) // remove LSP prefix
85+ snippet = snippet
86+ . replace ( regexPremeable , "" ) // remove any preamble from the line
87+ . replace ( regexLSPPrefix , "" ) // remove LSP prefix
88+ codeElem . innerText = snippet
8889 preElem . appendChild ( codeElem )
8990 divElem . appendChild ( preElem )
9091 } )
You can’t perform that action at this time.
0 commit comments