Code Monkey home page Code Monkey logo

Comments (4)

mikirejf avatar mikirejf commented on May 9, 2024 1

@TheGrandmother
You first need to transpile your code to ES5, if you want the plugin to work as expected. That way, all the variables get hoisted to the top of the scope.

  var cid, resp;
  return Promise.resolve().then(function () {
    return getCid(slackUsername);
  }).then(function (_resp) {
    cid = _resp;
    return replyFn(`Creating time report for ${year} ${month} and ${cid}`);
  }).then(function () {
    return request.post(config.apiUrl + `/create-time-report/${cid}/${year}/${month}`);
  }).then(function (_resp) {
    resp = _resp;
  });

from kneden.

loganfsmyth avatar loganfsmyth commented on May 9, 2024

Thanks for filing. Beware that this module is essentially unmaintained currently. Happy to leave this open, but it probably won't get fixed.

You may want to take a look at https://www.npmjs.com/package/fast-async

from kneden.

TheGrandmother avatar TheGrandmother commented on May 9, 2024

@loganfsmyth
Yhea I realized that, this has been another exercise in "don't just pull random npm packages" :p

Thanks for the tip! I siwtched to async-to-generators but fast-async seems much better :)

from kneden.

shellscape avatar shellscape commented on May 9, 2024

Getting this as well. Transpiling to ES5 for this to work is a major bummer, as my target is Node 6.

from kneden.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.