question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Not working with Async/Await

See original GitHub issue

How to make it work with async/await?

test.js

export default class Request {
  static async get() {
   return window.fetch("...");
  }
}

javascript-obfuscator test.js

On Windows Powershell:

               ^
Error: Line 2: Unexpected identifier
> ...tic async get() {...
    at Function.value (....\node_modules\javascript-obfuscator\dist\index.js:1:63377)
Exit code: 1

Tried yarn add using both #master branch and @latest

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:11 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
sanex3339commented, Mar 30, 2018

javascript-obfuscator@0.15.0 just published to the npm!

1reaction
sanex3339commented, Mar 26, 2018

I reopened issue untill 0.15.0 release

Read more comments on GitHub >

github_iconTop Results From Across the Web

Async/await - The Modern JavaScript Tutorial
In actuality, The `await` keyword breaks the synchronous flow and creates a new promise handler from every subsequent statement in the function; ...
Read more >
javascript async/await not working - Stack Overflow
I am using the async/await keywords, but not having any luck. Any help appreciated. This is my attempt to try getting it to...
Read more >
javascript - await does not wait for Promise to finish
So it's a bit weird. The "waiting" happens within that aync function, not your initial js function. consider this example
Read more >
Do not use forEach with async-await - gists · GitHub
The problem. Array.prototype.forEach is not designed for asynchronous code. (It was not suitable for promises, and it is not suitable for ...
Read more >
Use Promise.all to Stop Async/Await from Blocking Execution ...
In async functions, await blocks any code that follows from executing until the Promise has resolves, which means that our refactored code doesn't...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found