What's this yellow line?

Beneath this code (see below) a yellow line appears beneath “audio[0].volume = .10;” and “audio[0].addEventListener(‘ended’,function(e){” as if the application is telling me I’ve made a mistake. Right clicking the area provides no hints and the cross (error) icon that used to appear when mistakes were detected is nowhere to be found (I recently upgraded from v9 to v.10).

What’s it moaning about? The script works.

<script type="text/javascript">
    $(window).load(function(){
    var audio;
    var playlist;
    var tracks;
    var current;

    init();
    function init(){
        current = 0;
        audio = $('audio');
        playlist = $('#playlist');
        tracks = playlist.find('li a');
        len = tracks.length - 1;
        audio[0].volume = .10;
        playlist.find('a').click(function(e){
            e.preventDefault();
            link = $(this);
            current = link.parent().index();
            run(link, audio[0]);
        });
        audio[0].addEventListener('ended',function(e){
            current++;
            if(current == len){
                current = 0;
                link = playlist.find('a')[0];
            }else{
                link = playlist.find('a')[current];    
            }
            run($(link),audio[0]);
        });
    }
    function run(link, player){
            player.src = link.attr('href');
            par = link.parent();
            par.addClass('active').siblings().removeClass('active');
            audio[0].load();
            audio[0].play();
    }
    });
</script>

When I hover over that, I get a hint that in JavaScript the leading decimal point on “.10” can be confused with a dot (changing it to “0.10” removes the underline). I also get one on the “addEventListener” call about argument “e” being defined but never used…

I’m not sure but I’m guessing this is being provided by Komodo’s jshint checking?

1 Like

Yes it is. Linter warnings are yellow underlines.

1 Like

Didn’t think to hover. Thanks.
Hovering over the second line gives me nothing though :confused:

I get why it’s warning me since you pointed it out but it’d be nice if the text editor worked as intended.

There’s a problem with it for now. If you have more than 1 warnings on a line, then you won’t be able to see a popup.
Also there’s a problem with positioning the line you must hover on to see the popup on non-standard DPI’s.