chain-args

Give your functions a chaining api.

Usage no npm install needed!

<script type="module">
  import chainArgs from 'https://cdn.skypack.dev/chain-args';
</script>

README

Chain Args

NPM version Code Climate

Chain Args allows you to take a function you'd usually call like this:

setOptions({
    color: 'blue',
    amount: 8
    loud: true
});

And change it to a function you can call like this:

setOptions2()
    .color('blue')
    .amount(8)
    .loud(true);