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

Add single-letter variable warning in JS inlining #91

Merged
merged 2 commits into from
Jun 2, 2021

Conversation

bbugh
Copy link
Contributor

@bbugh bbugh commented May 31, 2021

Adds a warning to the interop inlining page about using single-letter variables in JavaScript inlining, to help others avoid getting bitten by mint-lang/mint#452

@gdotdesign
Copy link
Member

It's not quite correct, since the variables can be multiple letters like aa, xyz, etc... which could still cause the issue (less likely but still :))

I would say instead:

To be safe prefix your variable names with a dollar sign $.

@Sija
Copy link
Member

Sija commented Jun 1, 2021

I'd prefer to fix it on the mint side if possible.

@bbugh
Copy link
Contributor Author

bbugh commented Jun 1, 2021

I agree, and I'm not sure when that might happen. I spent quite a lot of time trying to figure this out especially being new to Mint, and I'd love to say others the trouble. 😅

@bbugh
Copy link
Contributor Author

bbugh commented Jun 1, 2021

Adjusted it for correctness

@gdotdesign gdotdesign merged commit 7b8d719 into mint-lang:master Jun 2, 2021
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.

3 participants