According to the section 9.2.6 of SSE standard:
The UTF-8 decode algorithm strips one leading UTF-8 Byte Order Mark (BOM), if any.
However eventsource-client does not handle the leading BOM head now.
To fix this bug, we can introduce a flag first_chunk in EventParser. The parser will check and skip the BOM during parsing the first chunk.
If it is OK, I'm happy to submit a PR for this~
According to the section 9.2.6 of SSE standard:
However
eventsource-clientdoes not handle the leading BOM head now.To fix this bug, we can introduce a flag
first_chunkinEventParser. The parser will check and skip the BOM during parsing the first chunk.If it is OK, I'm happy to submit a PR for this~