@@ -136,7 +136,7 @@ export function createLexer(buffer: string, options: LexerOptions = {}): LexerTo
136
136
const isNextEQ = nextChar === EQ ;
137
137
const isWS = isWhiteSpace ( char ) ;
138
138
// const isPrevWS = isWhiteSpace(prevChar);
139
- const isNextWS = nextChar && isWhiteSpace ( nextChar ) ;
139
+ const isNextWS = ! ! nextChar && isWhiteSpace ( nextChar ) ;
140
140
141
141
if ( stateSpecial && isSpecialChar ( char ) ) {
142
142
return true ;
@@ -202,7 +202,6 @@ export function createLexer(buffer: string, options: LexerOptions = {}): LexerTo
202
202
// detect case where we have '[My word [tag][/tag]' or we have '[My last line word'
203
203
const substr = chars . substrUntilChar ( closeTag ) ;
204
204
205
-
206
205
const hasInvalidChars = substr . length === 0 || substr . indexOf ( openTag ) >= 0 ;
207
206
const isNextCharReserved = nextChar && isCharReserved ( nextChar )
208
207
const isLastChar = chars . isLast ( )
@@ -241,7 +240,10 @@ export function createLexer(buffer: string, options: LexerOptions = {}): LexerTo
241
240
const silent = true ;
242
241
const tagStr = chars . grabWhile ( ( char ) => char !== closeTag , silent ) ;
243
242
const tagGrabber = createCharGrabber ( tagStr , { onSkip } ) ;
243
+ const eqParts = tagStr . split ( EQ ) ;
244
+ const isStartSingle = ! ! eqParts . length && ! eqParts [ 0 ] . includes ( SPACE ) && eqParts [ 0 ] [ 0 ] !== SLASH ;
244
245
const hasSpace = tagGrabber . includes ( SPACE ) ;
246
+ debugger
245
247
246
248
tagMode = TAG_STATE_NAME ;
247
249
0 commit comments