Skip to content

Bug- prism fails if the text in a code is empty line  #44

Open
@ObaidAshiq

Description

@ObaidAshiq

Description
When the user try to view the diff in split mode, if the old code and new code have, some empty line, prism throws error for syntax highlighting

Step to reproduce

  1. Use the Syntax Highlighting example
  2. Add some empty lines in new code variable, in the beggining (These variables should contain string value)
  3. Set split mode to true

Screenshot of error
image

Screenshot when split mode is false
image

Code sanbox
image
Link
Code sandbox example

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions