Problem with let in safari

Open
#9 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
25/100
Issue type
Bug
Clarity
Needs clarification
Activity status
Stale
Tech stack
javascript
Domain
build-system

Research direction

Reproduce the Meteor application’s production build with the --production flag and inspect the generated code shown in the report. Compare the Safari failure with the Chrome and Firefox results, then trace why a let declaration remains in the ES5 output. Done means the transpilation behavior is explained and a focused fix or confirmed upstream limitation is documented.

Written by the indexing model from the issue text.

Description

Hi, im having some trouble with transpiling my code to ES5. When i build with --production flag my meteor application it runs OK on chrome and firefox, but when i run it on safari it returns this error:
"SyntaxError: Cannot declare a let variable twice: 'e'."
In this place of the code ( which is some meteor code )
image

I know this error is a bug already reported from safari, but my question is: the let statement is a ES2015 feature, why is it not being transpiled to a var?

Dominant language
JavaScript
Stars
3
Forks
4
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from meteor/ecmascript-runtime

All issues in meteor/ecmascript-runtime

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.