Sha256: b752d1ee962083a6b4f1b069748d2c8e6c164c69cb0a7c64c5de91c628a1100f

Contents?: true

Size: 507 Bytes

Versions: 11

Compression:

Stored size: 507 Bytes

Contents

# -*- coding: utf-8 -*- #
# frozen_string_literal: true

module Rouge
  module Lexers
    load_lexer 'jsx.rb'
    load_lexer 'typescript/common.rb'

    class TSX < JSX
      extend TypescriptCommon

      title 'TSX'
      desc 'TypeScript-compatible JSX (www.typescriptlang.org/docs/handbook/jsx.html)'

      tag 'tsx'
      filenames '*.tsx'

      prepend :element_name do
        rule %r/(\w+)(,)/ do
          groups Name::Other, Punctuation
          pop! 3
        end
      end
    end
  end
end

Version data entries

11 entries across 11 versions & 2 rubygems

Version Path
rouge-3.28.0 lib/rouge/lexers/tsx.rb
rouge-3.27.0 lib/rouge/lexers/tsx.rb
rouge-3.26.1 lib/rouge/lexers/tsx.rb
mumukit-content-type-1.11.1 vendor/bundle/ruby/2.6.0/gems/rouge-3.26.0/lib/rouge/lexers/tsx.rb
rouge-3.26.0 lib/rouge/lexers/tsx.rb
rouge-3.25.0 lib/rouge/lexers/tsx.rb
rouge-3.24.0 lib/rouge/lexers/tsx.rb
rouge-3.23.0 lib/rouge/lexers/tsx.rb
rouge-3.22.0 lib/rouge/lexers/tsx.rb
rouge-3.21.0 lib/rouge/lexers/tsx.rb
rouge-3.20.0 lib/rouge/lexers/tsx.rb