Skip to content

Instantly share code, notes, and snippets.

@sgolemon
Created September 15, 2017 19:05
Show Gist options
  • Save sgolemon/fdb3cf049a7d73217fbc5f6ac6224c28 to your computer and use it in GitHub Desktop.
Save sgolemon/fdb3cf049a7d73217fbc5f6ac6224c28 to your computer and use it in GitHub Desktop.
PipeOp2 Usage
<?php
$x = "hello"
|> 'strtoupper'
|> function($x) { return $x . " world"; };
// $x === "HELLO world"
# LHS is any expression
# RHS is callable taking one arg (that arg being LHS output)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment