Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Double "</script>" output in JS language #8

Closed
Tekanewa opened this issue Aug 3, 2015 · 6 comments
Closed

Double "</script>" output in JS language #8

Tekanewa opened this issue Aug 3, 2015 · 6 comments
Assignees
Labels
Milestone

Comments

@Tekanewa
Copy link

Tekanewa commented Aug 3, 2015

Hi,

with v2.7.0, when attempting to highlight JS code that is also enclosed in the "<script type="text/javascript">" and "</script>" lines, Enlighter is outputting the "</script>" part twice at the end. While those two lines are of course not technically JS code (but usually included), v2.6.0 of Enlighter could render it just fine. This would be a sample code that causes the issue:

<script type="text/javascript">
    window.addEvent('domready', function() {
        // highlight all pre tags
        $('pre').light({
            altLines : 'hover',
            indent : 2,
            editable: false
        });
    });
</script>

Kalydon

@AndiDittrich
Copy link
Member

Dear Kalydon,
thanks for your feedback, i can confirm the issue.
I've replaced the complete tokenizer&rendering engine in the last release and will take a look on what's going wrong.

best regards, Andi

@AndiDittrich AndiDittrich self-assigned this Aug 3, 2015
@AndiDittrich AndiDittrich added this to the v2.8.0 milestone Aug 3, 2015
@AndiDittrich
Copy link
Member

the fix will be included within the next release. it's a bug within the new tokenizer (missing exit condition)

@Tekanewa
Copy link
Author

Tekanewa commented Aug 3, 2015

Andi,

that sounds great! Any idea when the next release will happen? If the release is still some time away, could you provide the fix here in this topic already, since highlighting JS code is fairly important for my usage.

Thank you!

Kalydon

@AndiDittrich
Copy link
Member

the release will follow in the next few hours

@Tekanewa
Copy link
Author

Tekanewa commented Aug 3, 2015

Andi,

that's just awesome! thanks for such a quick fix!

Kalydon

@AndiDittrich
Copy link
Member

v2.8.0 is out including the bugfix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants