GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — Lexical colorization/classification for template strings. by DanielRosenwasser · Pull Request #2026 · microsoft/TypeScript

Conversation

@DanielRosenwasser

@DanielRosenwasser Daniel Rosenwasser (DanielRosenwasser) commented Feb 13, 2015

Copy link
Copy Markdown
Member

Follow up to #1744 but for TypeScript 1.5.

This PR adds lexical classification support for template strings in the absence of a syntactic classifier.

It will break in the presence of

  • Nested template strings that span multiple lines.
  • Nested expressions composed of curly braces, where the closing curly falls on the next line.

But otherwise it is a fairly good approximation.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Daniel Rosenwasser (DanielRosenwasser) added 7 commits February 12, 2015 15:48
@DanielRosenwasser
Rudimentary, but imperfect, lexical classification for templates.
ea30c68
@DanielRosenwasser
Fixed issue with the kinds we check.
3429fab
@DanielRosenwasser
Addressed CR feedback.
f1f085e
@DanielRosenwasser
classifyKeywordsInGenerics -> syntacticClassifierAbsent
3fea0ae
@DanielRosenwasser
Added tests, fixed order of emptying templateStack, unconditionally p…
ab79fae
…erform template classification.
@DanielRosenwasser
Fixed assertion
1838800
@DanielRosenwasser
Added comment for 'syntacticClassifierAbsent'.
15b333e
@msftclas Microsoft Contribution License Agreements (msftclas) added the cla-not-required label Feb 13, 2015
@DanielRosenwasser Daniel Rosenwasser (DanielRosenwasser) mentioned this pull request Feb 13, 2015
Would be great if multiline strings were categorized differently #2005
Closed
@DanielRosenwasser
Added API baseline changes.
65e23b1
CyrusNajmabadi
CyrusNajmabadi reviewed Feb 13, 2015
View reviewed changes
Comment thread src/services/services.ts Outdated

@CyrusNajmabadi Cyrus Najmabadi (CyrusNajmabadi) Feb 13, 2015

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Comment the purpose of this parameter so that consumers of the LS know what they should pass and how hte classifiers interact

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
Daniel Rosenwasser (DanielRosenwasser) added 2 commits February 13, 2015 12:56
@DanielRosenwasser
Addressed CR feedback.
1dca562
@DanielRosenwasser
Added baselines.
a1b90f0
Daniel Rosenwasser (DanielRosenwasser) added a commit that referenced this pull request Feb 13, 2015
@DanielRosenwasser
Merge pull request #2026 from Microsoft/lexicalTemplateStringsOnMaster
efed5f0
Lexical colorization/classification for template strings.
@DanielRosenwasser
Daniel Rosenwasser (DanielRosenwasser) merged commit efed5f0 into master Feb 13, 2015
@DanielRosenwasser
Daniel Rosenwasser (DanielRosenwasser) deleted the lexicalTemplateStringsOnMaster branch February 13, 2015 22:07
This was referenced Feb 13, 2015
Template string aren't recognized by classifier #1884
Closed
String templates not colorized in VS 2013 #1698
Closed
Template string syntax highlighting (release-1.4) #1477
Closed
@DanielRosenwasser Daniel Rosenwasser (DanielRosenwasser) mentioned this pull request Jun 25, 2015
Strange colourisation of template strings when "#/" present after first placeholder #3630
Closed
@microsoft Microsoft (microsoft) locked and limited conversation to collaborators Jun 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

5 participants

@DanielRosenwasser @yuit @rbuckton @CyrusNajmabadi @msftclas
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.