Giter Site home page Giter Site logo

suguru03 / aigle Goto Github PK

View Code? Open in Web Editor NEW
334.0 334.0 18.0 5.57 MB

πŸ¦… Aigle is an ideal promise library which is faster and more efficient than other libraries. It is a production-ready library that implements the Promise A+ standard.

License: MIT License

JavaScript 97.70% TypeScript 2.25% CSS 0.05%
aigle async javascript nodejs promise

aigle's People

Contributors

adrian-gierakowski avatar asmgf avatar dependabot[bot] avatar greenkeeper[bot] avatar nak1b avatar qsona avatar suguru03 avatar talentben avatar thammin 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  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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

aigle's Issues

Progress information

First of all, thanks for this library, it looks amazing!

I discovered it because I'm async contributor and I needed a Promise based alternative.

The issue is related with p-progress, that reports you information about tasks progress.

For example: https://github.com/sindresorhus/p-progress/blob/master/example.js

Because you need to manually increment the progress counter, could be easy do this internally into aigle methods for increment the counter based in each step of the .parallel, .series, .each, .etc methods.

It could be expose as .onProgress method for get information about the job state.

The thing is, do you think make sense and could be useful expose this information?

Multiple Asyncs?

When I use Aigle to promisifyAll(require('fs')) I end up with multiple leveled Async functions. For example, for readFile() I end up with:

readFile: [Function],
readFileAsync: [Function],
readFileAsyncAsync: [Function],
readFileAsyncAsyncAsync: [Function],

Path seems to fair worse on almsot all functions:

resolve: [Function: resolve],
resolveAsync: [Function],
resolveAsyncAsync: [Function],
resolveAsyncAsyncAsync: [Function],
resolveAsyncAsyncAsyncAsync: [Function],
resolveAsyncAsyncAsyncAsyncAsync: [Function],
resolveAsyncAsyncAsyncAsyncAsyncAsync: [Function],
resolveAsyncAsyncAsyncAsyncAsyncAsyncAsync: [Function]

Why?

PS: bluebird does not seem to suffer from this. I get one Async promise-returning function for each function in a library.

README doc error

return Aigle.map([1.1, 1.4, 2.2], n => Aigle.delay(10, n * 2)) // [2.2, 2.8, 4.4]
.uniqBy(n => Aigle.delay(10, Math.floor(n))) // [2.2, 4.4] ==> [2,4]
.sum() // 6.6 ==> [6]
.times() // [0, 1, 2, 3, 4, 5];
.then(value => console.log(value)); // [0, 1, 2, 3, 4, 5];

Promise.resolve should consider itself as a promise


const Aigle = require('aigle');
global.Promise = Aigle
Promise.resolve(Promise.resolve(1)).then(value => console.log('the resolved value is ',value));

The code above will console
the resolved value is Aigle { _resolved: 1, _value: 1, _key: undefined, _receiver: undefined, _onFulfilled: undefined, _onRejected: undefined, _receivers: undefined }

I think the correct console should be the resolved value is 1。

https://github.com/suguru03/aigle/blob/master/lib/aigle.js#L3633
should add a judge here


function _resolve(value) {
  if (value instanceof Aigle) {
      return value;
  }
  const promise = new Aigle(INTERNAL);
  promise._resolved = 1;
  promise._value = value;
  return promise;
}

Publish pre-compiled version for ES5

Hello !

I encountered an issue with aigle when trying to use it in production.

I am developing a React app based on Create React App. When I try to build it in production, it fails at minification step because of aigle as its code is not compiled for ES5. You can have more details here: npm run build fails to minify

Could you publish a pre-compiled version of aigle compatible with ES5 ?

Thanks a lot !

Suggestion: Split up core and features

This looks very impressive πŸ‘ I suggest splitting out Promise spec implementation and additions into separate modules so that the Promise could just be used as a polyfill.

promisify - getBuffer is not a function

This is in an angular application:

let uri = await Aigle.promisify(this.carImage.getBase64)(Jimp.MIME_PNG)

where this.carImage is an image from jimp

Results in:

Error: Uncaught (in promise): TypeError: this.getBuffer is not a function

An in-range update of buble is breaking the build 🚨

The devDependency buble was updated from 0.19.4 to 0.19.5.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

buble is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • βœ… ci/circleci: Your tests passed on CircleCI! (Details).
  • ❌ continuous-integration/travis-ci/push: The Travis CI build failed (Details).

Commits

The new version differs by 34 commits.

  • a4d66ef -> v0.19.5
  • 08be12b Transpile U+2028 and U+2029 (json-superset)
  • 59d1127 Hopefully fix travis file syntax
  • 1593577 Try to make register test run in node4
  • 85d74e0 Stricter and faster travis setup
  • eb0f3c5 Add simple test for register.js functionality
  • 7ddf225 Correctly transpile computed xor spread properties
  • 7e7e9e7 Add class /@PURE/ annotations to tests
  • 8e87c35 Add /@PURE/ comment annotation to class IIFE
  • 24b1fab Allow disabling spread properties transpiling
  • 9a79122 Add objectRestSpread support data
  • ab84650 Add support info for async/await
  • bc02c36 Add support data for newer engine versions
  • f311900 Mark Safari 9 as not supporting argument destructuring
  • fd0cbb5 Mark more engines as not supporting const/let

There are 34 commits in total.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Typescript returns Aigle as undefined

Hello
I am not sure if typescript is fully completed but when I try to import Aigle as mentioned in the doc, I am getting Aigle as undefined which fails all my calls. E.g. Agile.eachLimit throws an error 'Cannot read propery eachLimit of undefined'. However the below code works fine.

import * as Aigle from 'aigle'
then Aigle.default.eachLimit

An in-range update of uglify-js is breaking the build 🚨

The devDependency uglify-js was updated from 3.4.10 to 3.5.0.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

uglify-js is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ ci/circleci: Your tests failed on CircleCI (Details).

Release Notes for v3.5.0

Β 

Commits

The new version differs by 8 commits.

  • fd78859 v3.5.0
  • 143f905 fix corner case in sequences (#3350)
  • f2286c3 enhance unsafe for Array (#3349)
  • b9615f7 improve compress performance (#3348)
  • c520e99 enhance comparisons (#3347)
  • 615ae37 introduce assignments (#3345)
  • 7aa7f21 fix corner case in evaluate (#3344)
  • 4430a43 fix corner case in inline (#3343)

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

mixin lodash _.chain().value() not work

const _ = require('lodash');
const Aigle = require('aigle');
Aigle.mixin(_);

function asyncFunc(n) {
return new Promise(resolve => setTimeout(resolve, 10, n * 2));
}

main=async function() {
// example 1
const array = [1, 2, 3];
const result_1 = await Aigle.map(array, asyncFunc);

// example 2
const result_2 = await Aigle.chain(array)
.map(asyncFunc)
.sum()
.value();
// or
const result_3 = await Aigle.resolve(array)
.map(asyncFunc)
.sum();

const result_4 = await Aigle.map(array, asyncFunc)
.sum();

console.log(result_1,result_2,result_3,result_4)
}()
// ==> [ 2, 4, 6 ] undefined 12 12
// should result_2 == result_4
β”œβ”€β”¬ [email protected]
β”‚ └── [email protected]
β”œβ”€β”€ [email protected]

Collection uniformity

I was checking about Aigle.parallel and I found at least exist 3 methods for do technically the same, but using different input. Specifically I'm referrencing this methods:

- Aigle.all
- Aigle.props

That basically could be expose just in one

- Aigle.parallel

The think I'm suggesting is avoid expose overhead methods for make easy use the same method all the time, because:

  • Technically doing the same, so input is a implementation detail.
  • Less methods to learn.
  • Tiny API.

For example, taking lodash as example, see lodash.forEach method. You can use it for objects or arrays, and it's so powerful; the point is it is not distinguishing between two methods; just one for Collection an abstraction of data type that include array and object (like Iterable).

What do you think?

An in-range update of uglify-js is breaking the build 🚨

Version 3.0.16 of uglify-js just got published.

Branch Build failing 🚨
Dependency uglify-js
Current Version 3.0.15
Type devDependency

This version is covered by your current version range and after updating it in your project the build failed.

As uglify-js is β€œonly” a devDependency of this project it might not break production or downstream projects, but β€œonly” your build or test tools – preventing new deploys or publishes.

I recommend you give this issue a high priority. I’m sure you can resolve this πŸ’ͺ

Status Details
  • βœ… ci/circleci Your tests passed on CircleCI! Details
  • βœ… continuous-integration/travis-ci/push The Travis CI build passed Details
  • βœ… codecov/patch Coverage not affected. Details
  • ❌ codecov/project No report found to compare against Details

Release Notes v3.0.16

Β 

Commits

The new version differs by 23 commits.

  • 4231f73 v3.0.16
  • da2de35 add comment about quote_style and gzip (#2092)
  • 41beae4 cache web assets between CI runs (#2089)
  • 82db918 fix CLI parsing of --source-map content (#2088)
  • 3dc9e14 add Node.js 8 to Travis CI (#2086)
  • fed0096 allow expect_stdout to specify Error (#2087)
  • 2bdc880 fix variable accounting in inline (#2085)
  • 5ef7cb3 suppress false positives for-in loops (#2080)
  • 4ad7b1d fix portability of sandbox.run_code() on Node.js 0.1x (#2078)
  • 9186859 fix non-string parameters (#2076)
  • 47c0713 report test/ufuzz.js failures in process.stderr (#2074)
  • 293c566 marshal mangle[.properties].reserved from non-Array values (#2072)
  • 9c30640 fix iteration over object with inherited properties (#2068)
  • 9db0695 fix cascade on multi-branch evaluations (#2067)
  • f2af093 fix CLI output corruption (#2061)

There are 23 commits in total.

See the full diff

Not sure how things should work exactly?

There is a collection of frequently asked questions and of course you may always ask my humans.


Your Greenkeeper Bot 🌴

Not clear how to use `Aigle` VS `Native JS`?

I am a newbie for Callback, Promise, Async/Await.
But I understand that we use Async/Await to wait running before to continue.
I tried

async function aigleFn(array) {
  const users = await Aigle.map(array, val=>{
  .....
  });
  console.log('Done!')
}
aigleFn([1,2,3,4,5])
----
async function nativeFn(array) {
  const users = await array.map( val=>{
  .....
  });
  console.log('Done!')
}
nativeFn([1,2,3,4,5])

What difference?

Add flow method

Hello,

I noted async flow method is missing.

It's very useful and implementation is pretty simple:

const asyncFlow = fns => data =>
  aigle.reduce(fns, (acc, fn) => fn(data, acc), data)

Happy to make a PR if you are going to accept it.

Related with #70

Rename pick/omit to pickBy/omitBy

These functions will be renamed.

functions

  • pick -> pickBy
  • omit -> omitBy

new functions

  • pick
  • omit

These functions are the almost same as pickBy/omitBy, but shorthand will be different.

// current 
const collection = {
  a: { bool: 0 },
  b: { bool: 1 },
  c: { bool: 1 }
};
Aigle.pick(collection, 'bool'); // { b: {}, c: {} }
_.pick(collection, 'bool'); // {}
_.pickBy(collection, 'bool'); // { b: {}, c: {} }

// after 
Aigle.pick(object, 'a');  // { a: {} }
Aigle.pick(object, 'bool');  // {}
Aigle.pickBy(object, 'bool'); // { b: {}, c: {} }

promisifyAll Example less createClient

const redis = require('redis');
Aigle.promisifyAll(redis);

const key = 'test';
redis.hsetAsync(key, 1)
  .then(() => redis.hgetAsync(key))
  .then(value => console.log(value)); // 1

must createClient

const redis = require('redis').createClient()
Aigle.promisifyAll(redis)

Update filter functionality

Add a default iterator which has the same functionality as lodash filter's iterator.

Aigle.map([1, 2, 3, 4], n => Aigle.resolve(n % 2))
  .filter()
  .then(console.log); // [1, 1]

An in-range update of prettier is breaking the build 🚨

The devDependency prettier was updated from 1.14.2 to 1.14.3.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

prettier is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • βœ… ci/circleci: Your tests passed on CircleCI! (Details).
  • ❌ continuous-integration/travis-ci/push: The Travis CI build failed (Details).

Release Notes for 1.14.3

πŸ”— Changelog

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

An in-range update of mocha is breaking the build 🚨

The devDependency mocha was updated from 6.0.2 to 6.1.0.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

mocha is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ ci/circleci: Your tests failed on CircleCI (Details).

Release Notes for v6.1.0

6.1.0 / 2019-04-07

πŸ”’ Security Fixes

  • #3845: Update dependency "js-yaml" to v3.13.0 per npm security advisory (@plroebuck)

πŸŽ‰ Enhancements

  • #3766: Make reporter constructor support optional options parameter (@plroebuck)
  • #3760: Add support for config files with .jsonc extension (@sstephant)

πŸ“  Deprecations

These are soft-deprecated, and will emit a warning upon use. Support will be removed in (likely) the next major version of Mocha:

πŸ› Fixes

  • #3829: Use cwd-relative pathname to load config file (@plroebuck)
  • #3745: Fix async calls of this.skip() in "before each" hooks (@juergba)
  • #3669: Enable --allow-uncaught for uncaught exceptions thrown inside hooks (@givanse)

and some regressions:

πŸ“– Documentation

πŸ”© Other

  • #3830: Replace dependency "findup-sync" with "find-up" for faster startup (@cspotcode)
  • #3799: Update devDependencies to fix many npm vulnerabilities (@XhmikosR)
Commits

The new version differs by 28 commits.

  • f4fc95a Release v6.1.0
  • bd29dbd update CHANGELOG for v6.1.0 [ci skip]
  • aaf2b72 Use cwd-relative pathname to load config file (#3829)
  • b079d24 upgrade deps as per npm audit fix; closes #3854
  • e87c689 Deprecate this.skip() for "after all" hooks (#3719)
  • 81cfa90 Copy Suite property "root" when cloning; closes #3847 (#3848)
  • 8aa2fc4 Fix issue 3714, hide pound icon showing on hover header on docs page (#3850)
  • 586bf78 Update JS-YAML to address security issue (#3845)
  • d1024a3 Update doc examples "tests.html" (#3811)
  • 1d570e0 Delete "/docs/example/chai.js"
  • ade8b90 runner.js: "self.test" undefined in Browser (#3835)
  • 0098147 Replace findup-sync with find-up for faster startup (#3830)
  • d5ba121 Remove "package" flag from sample config file because it can only be passes as CLI arg (#3793)
  • a3089ad update package-lock
  • 75430ec Upgrade yargs-parser dependency to avoid loading 2 copies of yargs

There are 28 commits in total.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Implements Async functions

Collections

  • each/forEach
  • eachSeries/forEachSeries
  • eachLimit/forEachLimit
  • map
  • mapSeries
  • mapLimit
  • mapValues
  • mapValuesSeries
  • mapValuesLimit
  • filter
  • filterSeries
  • filterLimit
  • reject
  • rejectSeries
  • rejectLimit
  • find/detect
  • findSeries/detectSeries
  • findLimit/detectLimit
  • pick
  • pickSeries
  • pickLimit
  • omit
  • omitSeries
  • omitLimit
  • reduce
  • transform
  • transformSeries
  • transformLimit
  • sortBy
  • sortBySeries
  • sortByLimit
  • some
  • someSeries
  • someLimit
  • every
  • everySeries
  • everyLimit
  • concat
  • concatSeries
  • concatLimit
  • groupBy
  • groupBySeries
  • groupByLimit

control Flow

  • parallel
  • whilst
  • DoWhilst
  • until
  • doUntil
  • retry
  • times
  • timesSeries
  • timesLimit

Ensure object property order

Aigle functions should return the same order (it is not ensured by engines).

(async () => {
  const obj1 = {
    task1: Aigle.delay(30, 1),
    task2: Aigle.delay(20, 2),
    task3: Aigle.delay(10, 3)
  };
  const res1 = await Aigle.props(obj1);
  console.log(res1);
  // { task3: 3, task2: 2, task1: 1 }
  // ↓
  // { task1: 1, task2: 2, task3: 3 }

  const obj2 = {
    task1: 1,
    task2: 2,
    task3: 3
  };
  const res2 = await Aigle.mapValues(obj2, val => Aigle.delay(val * 10, val));
  console.log(res2);
  // { task3: 3, task2: 2, task1: 1 }
  // ↓
  // { task1: 1, task2: 2, task3: 3 }
})();

promisify a function has More than two params

v1.11

promisify a function that callback function has More than two params

e.q.

const { exec } = require('child_process');
const exec_1 =  require('util').promisify(exec);
const exec_2 = require('aigle').promisify(exec);

const cmd = 'ls 1>&2';
exec_1(cmd).then(raw=> console.log('exec 1=>',raw)).catch(e=>console.log('exec 1 error=>',e));
exec_2(cmd).then(raw=> console.log('exec 2=>',raw)).catch(e=>console.log('exec 2 error=>',e));

.result

exec 1 => { stdout: '',  stderr: 'a.file'}
exec 2 => 

Update benchmarks for latest node versions

Would you be able to re-run the benchmarks and update them to reflect how fast Aigle is and how it compares to native-async-await in both Node 10.x and Node 11.x

I believe there have been significant performance improvements with Promises in 10.x and probably even faster in 11.x, but we don't know until it is tested.

Incompatible with create-react-app

This library is incompatible with create-react-app since it uses UglifyJS2 in it's toolchain, which does not support the destructuring in imports.

Ref terinjokes/gulp-uglify#66

When we try to build our app, we receive

Name expected [./~/aigle/lib/internal/collection.js:3,0][static/js/main.7201b8fd.js:151,6]

create-react-app is the official recommended bootstrap project to create React apps. It is recommended to make this library make this library compatible so we can reach more users.

Extends Aigle.parallel functionality

I'm thinking to extend Aigle.parallel functionality as below,

(async () => {
  const array1 = await Aigle.parallel([
    (async () => 1)(),
    (async () => 2)(),
    (async () => 3)(),
  ]);
  console.log(array1); // [1, 2, 3]
  const array2 = await Aigle.parallel([
    async () => 1,
    async () => 2,
    async () => 3,
  ]);
  console.log(array2); // [[AsyncFunction], [AsyncFunction], [AsyncFunction]]
})();

// ↓

(async () => {
  const array3 = await Aigle.parallel([
    async () => 1,
    async () => 2,
    async () => 3,
  ]);
  console.log(array3); // [1, 2, 3]
})();

Also, I'll add Aigle.series and Aigle.parallelLimit which are smilar to async.series and async.parallelLimit.

An in-range update of husky is breaking the build 🚨

The devDependency husky was updated from 1.2.0 to 1.2.1.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

husky is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • βœ… ci/circleci: Your tests passed on CircleCI! (Details).
  • ❌ continuous-integration/travis-ci/push: The Travis CI build failed (Details).

Commits

The new version differs by 7 commits.

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Object.assign found in aigle-es5.min.js

I found that the aigle-es5.min.js in the npm package contains Object.assign even though it was only introduced with ES6/ES2015. Also, despite its min.js name, the file is not minified. Can you please look into these? Thank you!

Missing Async Control Flow Methods

Hi @suguru03,
Very nice library, I found this after looking for a good promise library, however I noticed that some control flow methods are missing from this library that are present in both async and neo-async, notably:
waterfall
queue
priorityQueue
cargo

Is there any plans to add these functions? These seem particularly useful and I would love to see them implemented if possible.

Thanks!

Adding allSettled function as in Q library

Q library implementation:

/**
 * Turns an array of promises into a promise for an array of their states (as
 * returned by `inspect`) when they have all settled.
 * @param {Array[Any*]} values an array (or promise for an array) of values (or
 * promises for values)
 * @returns {Array[State]} an array of states for the respective values.
 */
Promise.prototype.allSettled = function () {
    return this.then(function (promises) {
        return all(array_map(promises, function (promise) {
            promise = Q(promise);
            function regardless() {
                return promise.inspect();
            }
            return promise.then(regardless, regardless);
        }));
    });
};

reduce in parallel

I note that

aigle
    .reduce(links, iterator, {})
    .then(data => emitter.emit('end', data))

resolve the promise in series. Is this intentional?

An in-range update of mocha is breaking the build 🚨

The devDependency mocha was updated from 6.0.0 to 6.0.1.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

mocha is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ ci/circleci: Your tests failed on CircleCI (Details).

Release Notes for v6.0.1

6.0.1 / 2019-02-21

The obligatory round of post-major-release bugfixes.

πŸ› Fixes

These issues were regressions.

  • #3754 - Mocha again finds test.js when run without arguments (@plroebuck)
  • #3756 - Mocha again supports third-party interfaces via --ui (@boneskull)
  • #3755 - Fix broken --watch (@boneskull)
  • #3759 - Fix unwelcome deprecation notice when Mocha run against languages (CoffeeScript) with implicit return statements; returning a non-undefined value from a describe callback is no longer considered deprecated (@boneskull)

πŸ“– Documentation

Commits

The new version differs by 9 commits.

  • 6d3d6b4 Release v6.0.1
  • 2146ece update CHANGELOG.md for v6.0.1
  • 7c9221d backout deprecation of value returned from suite; closes #3744
  • b7cfceb fix --watch not finding any files to execute; closes #3748
  • b836d73 Upgrade docdash version - issue #3663
  • 7926f47 fix --ui issues, closes #3746
  • 00f2ed9 dev dep upgrades from "npm audit" and "npm upgrade"
  • 34afb1a fix(cli/run.js): Revert default glob to match Mocha-5.2
  • 6d5a0db Bring the example congfiguration file in line with the documentation. (#3751)

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

aigle mixin lodash use chain thru get diff result

const _ = require('lodash');
const _$ = require('aigle')
$.mixin();

var main = (async function() {
const collection = [1, 4, 2];

var result1 = await _$.chain(collection).thru((e) => {
    console.log('do aigle', e);
    return e;
}).value();
console.log('aigle result', result1);

//do aigle 1
//do aigle 4
//do aigle 2
//aigle result 1

var result2 = await _.chain(collection).thru((e) => {
    console.log('do lodash', e);
    return e;
}).value();
console.log('lodash result', result2);

//do lodash [ 1, 4, 2 ]
//lodash result [ 1, 4, 2 ]

var result3 = await _$.chain(collection).then((e) => {
    console.log('do aigle then', e);
    return e;
}).value();
console.log('aigle then result', result3);

//do aigle then [ 1, 4, 2 ]
//aigle then result [ 1, 4, 2 ]
})()

An in-range update of lint-staged is breaking the build 🚨

The devDependency lint-staged was updated from 8.1.4 to 8.1.5.

🚨 View failing branch.

This version is covered by your current version range and after updating it in your project the build failed.

lint-staged is a devDependency of this project. It might not break your production code or affect downstream projects, but probably breaks your build or test tools, which may prevent deploying or publishing.

Status Details
  • ❌ ci/circleci: Your tests failed on CircleCI (Details).

Release Notes for v8.1.5

8.1.5 (2019-03-01)

Bug Fixes

  • fix issue with scoped pkg listr-update-renderer (#587) (63b085f), closes #585
Commits

The new version differs by 2 commits.

  • 63b085f fix: fix issue with scoped pkg listr-update-renderer (#587)
  • 1303573 docs: Update screencast and installation instructions

See the full diff

FAQ and help

There is a collection of frequently asked questions. If those don’t help, you can always ask the humans behind Greenkeeper.


Your Greenkeeper Bot 🌴

Implements Bluebird functions

Core

  • finally
  • spread
  • join

Collections

  • props

Promisification

  • promisify
  • promisifyAll

Resource Management

  • using
  • disposer

Timers

  • delay
  • timeout

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.