Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Add tslint rules for #3994#4458

Merged
weswigham merged 6 commits into
microsoft:mastermicrosoft/TypeScript:masterfrom
weswigham:tslint-rulesweswigham/TypeScript:tslint-rulesCopy head branch name to clipboard
Sep 18, 2015
Merged

Add tslint rules for #3994#4458
weswigham merged 6 commits into
microsoft:mastermicrosoft/TypeScript:masterfrom
weswigham:tslint-rulesweswigham/TypeScript:tslint-rulesCopy head branch name to clipboard

Conversation

@weswigham

Copy link
Copy Markdown
Member

@weswigham

Copy link
Copy Markdown
Member Author

Ping @DanielRosenwasser for some input. (specifically on the inference rule - is it even possible to recover that kind of info from the checker right now?)

@jkillian

Copy link
Copy Markdown

These seem like good rule concepts, any interest in contributing some/all of these directly to TSLint? If not, we'll probably go ahead and add at least some of them ourselves

@weswigham

Copy link
Copy Markdown
Member Author

I'd probably say to go for it - which ones are you interested in?

@adidahiya

Copy link
Copy Markdown
Contributor

I'm mainly interested in bringing no-inferrable-types into the core rules.

There seems to be interest in something like next-line as well, but we already have a thread going for that: palantir/tslint#88

@jkillian

Copy link
Copy Markdown

I thought maybe no-null as well? Seems like something people might want

@adidahiya

Copy link
Copy Markdown
Contributor

I'd like to wait until we see more demand for a no-null-keyword rule -- mainly because I'd like to create another contradictory rule that forbids implicit type casts for null checks (and encourages == null): palantir/tslint#625

Comment thread scripts/tslint/noInferrableTypesRule.ts Outdated

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider TemplateExpression as well

@weswigham

Copy link
Copy Markdown
Member Author

@DanielRosenwasser feedback integrated.

@DanielRosenwasser

Copy link
Copy Markdown
Member

👍

@weswigham

Copy link
Copy Markdown
Member Author

@mhegazy would you like to 👍 this?

@mhegazy

mhegazy commented Sep 17, 2015

Copy link
Copy Markdown
Contributor

👍

weswigham added a commit that referenced this pull request Sep 18, 2015
@weswigham weswigham merged commit e813963 into microsoft:master Sep 18, 2015
@jkillian

Copy link
Copy Markdown

Just fyi: we're working on adding this to tslint. I've added checking for parameter declarations as well as variable declarations. Feel free to leave feedback if you have any: palantir/tslint#690

@weswigham weswigham deleted the tslint-rules branch August 17, 2017 23:03
@microsoft microsoft locked and limited conversation to collaborators Jun 19, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.