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

Set isNewIdentifierLocation to true for JavaScript files#10391

Merged
jramsay merged 2 commits into
mastermicrosoft/TypeScript:masterfrom
SetIsNewIdentifierLocationToTrueForJSmicrosoft/TypeScript:SetIsNewIdentifierLocationToTrueForJSCopy head branch name to clipboard
Aug 17, 2016
Merged

Set isNewIdentifierLocation to true for JavaScript files#10391
jramsay merged 2 commits into
mastermicrosoft/TypeScript:masterfrom
SetIsNewIdentifierLocationToTrueForJSmicrosoft/TypeScript:SetIsNewIdentifierLocationToTrueForJSCopy head branch name to clipboard

Conversation

@jramsay

@jramsay jramsay commented Aug 17, 2016

Copy link
Copy Markdown
Member

Issue: Completion list auto-select is leading to a poor editing experience in JS files for Salsa
ex: var test = "test";
test.at auto-selects test.charAt

This is fine for TS where all completion items are high confidence. For JS, the completion lists will often contain low confidence items (identifiers in file) so auto-selecting is undesirable.

Fix: Always set isNewIdentifierLocation to true for JavaScript files. This ensures that for JS completions IsBuilder is true and auto-select is disabled.

Comment thread src/services/services.ts Outdated
}

return { isMemberCompletion, isNewIdentifierLocation, entries };
return { isMemberCompletion, isNewIdentifierLocation: isSourceFileJavaScript(sourceFile) ? true : isNewIdentifierLocation, entries };

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

isNewIdentifierLocation || isSourceFileJavaScript(sourceFile)

@vladima

vladima commented Aug 17, 2016

Copy link
Copy Markdown
Contributor

👍 with a minor suggestion

@jramsay

jramsay commented Aug 17, 2016

Copy link
Copy Markdown
Member Author

Thanks - like the suggestion.

@jramsay jramsay merged commit 7a9f8c8 into master Aug 17, 2016
@jramsay jramsay deleted the SetIsNewIdentifierLocationToTrueForJS branch August 17, 2016 20:58
@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.

3 participants

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