Giter Club home page Giter Club logo

async-chainable's People

Contributors

davidporter-id-au avatar hash-bang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

hertzg jack541108

async-chainable's Issues

Not a issue, consideration about TODO

Hey @hash-bang I think you should keep using next as a parameter and not use the context to expose it.

If you use a binded function as callback, you can't set the context, so the next method will be missing in that context, and your "promise" will never be resolved.

Anyway, great job! It's very good lib.

ERROR: Cannot use "await" as an identifier here

I got this code:

import asyncChainable from 'async-chainable'

asyncChainable()
    .then((next) => {
      console.log('first')
      next()
    })
    .then((next) => {
      console.log('second')
      next()
    })
    .start()

But when I compile it I get error:

11:33:13 [vite] hmr update /src/views/HomeView.vue
X [ERROR] Cannot use "await" as an identifier here:

    node_modules/.pnpm/[email protected]/node_modules/async-chainable/index.js:372:9:
      372 │ function await() {
          ╵          ~~~~~

11:33:16 [vite] error while updating dependencies:
Error: Build failed with 1 error:
node_modules/.pnpm/[email protected]/node_modules/async-chainable/index.js:372:9: ERROR: Cannot use "await" as an identifier here:
    at failureErrorWithLog (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:1604:15)
    at C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:1056:28
    at runOnEndCallbacks (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:1476:61)  
    at buildResponseToResult (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:1054:7)
    at C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:1166:14
    at responseCallbacks.<computed> (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:701:9)
    at handleIncomingPacket (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:756:9)
    at Socket.readFromStdout (C:\Users\username\Documents\GitHub\project\node_modules\.pnpm\[email protected]\node_modules\esbuild\lib\main.js:677:7)
    at Socket.emit (node:events:512:28)
    at addChunk (node:internal/streams/readable:324:12)

I use:

Node: v19.6.0
Vite: 4.0.0 win32-x64

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.