Skip to content

Add support for Typescript files #26

Open
@etagwerker

Description

@etagwerker

We could add .ts as an extension to the project:

PATTERNS = {
rb: {
line_comment: /^\s*#/,
begin_block_comment: /^=begin/,
end_block_comment: /^=end/,
class: /^\s*class\s+[_A-Z]/,
method: /^\s*def\s+[_a-z]/,
},
js: {
line_comment: %r{^\s*//},
begin_block_comment: %r{^\s*/\*},
end_block_comment: %r{\*/},
method: /function(\s+[_a-zA-Z][\da-zA-Z]*)?\s*\(/,
},
coffee: {
line_comment: /^\s*#/,
begin_block_comment: /^\s*###/,
end_block_comment: /^\s*###/,
class: /^\s*class\s+[_A-Z]/,
method: /[-=]>/,
},
feature: {
class: /^\s*Feature:/,
method: /^\s*Scenario:/,
}
}

Some projects use Typescript instead of vanilla JS.

Requested by @arielj

Metadata

Metadata

Assignees

No one assigned

    Labels

    good-first-issueIf you want to start contributing, this is a good place to start : )

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions