Uploaded image for project: 'Bitbucket Data Center'
  1. Bitbucket Data Center
  2. BSERV-12857

Syntax highlighting is incorrect for certain JavaScript use cases

    XMLWordPrintable

Details

    Description

      Issue Summary

      For certain use cases of JavaScript, the syntax highlighting that is used when displaying the source of .js files is incorrect.

      Steps to Reproduce

      1. Have a .js file with the following content
        public something(callback: callback, options?: ConsumerOptions): Promise<Consumer> {
        	console.info(`[${this.constructor.name}] Consumer creating.`);
        
        	this.consumer = Consumer.create({
        		...options,
        		queueUrl: await this.getUrl(),
        		handleMessage: message => {
        			if (message.Body){
        				message.Body = JSON.parse(message.Body);
        			}
        		}
        	})
        }
        
      2. View the file in source view

      Expected Results

      The syntax is highlighted consistently, something like this way:

      Actual Results

      The syntax is highlighted incorrectly:

      Workaround

      Currently there is no known workaround for this behavior. A workaround will be added here when available

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              cglockner Christian Glockner
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Backbone Issue Sync