Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better handling for createStringLiteral #292

Merged
merged 3 commits into from
Jan 30, 2021

Conversation

TwitchBronBron
Copy link
Member

the createStringLiteral function was not wrapping the value in quotes, which was unintuitive since it's not obvious that TokenKind.StringLiteral's value should be wrapped in quotes. This PR wraps the value if the quotes are missing, or leaves the value alone if at least one quotemark is found.

src/astUtils/creators.ts Outdated Show resolved Hide resolved
@TwitchBronBron TwitchBronBron merged commit d8d37ee into master Jan 30, 2021
@TwitchBronBron TwitchBronBron deleted the createStringLiteral-fix branch January 30, 2021 20:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants