http://plnkr.co/edit/2aIgMzUx7XgZe9EA6upB?p=preview&open=app%2Fapp.component.ts
http://plnkr.co/edit/EIsS2pFsDwATaq1Ibxvb?p=preview
http://plnkr.co/edit/hCCEtt1SVohWN80s0ej8?p=preview&open=app%2Fapp.component.ts
| codecov: | |
| token: uuid # Your private repository token | |
| url: "http" # for Codecov Enterprise customers | |
| slug: "owner/repo" # for Codecov Enterprise customers | |
| branch: master # override the default branch | |
| bot: username # set user whom will be the consumer of oauth requests | |
| ci: # Custom CI domains if Codecov does not identify them automatically | |
| - ci.domain.com | |
| - !provider # ignore these providers when checking if CI passed | |
| # ex. You may test on Travis, Circle, and AppVeyor, but only need |
| // === Arrays | |
| var [a, b] = [1, 2]; | |
| console.log(a, b); | |
| //=> 1 2 | |
| // Use from functions, only select from pattern | |
| var foo = () => { | |
| return [1, 2, 3]; |
| echo 'export PATH=$HOME/local/bin:$PATH' >> ~/.bashrc | |
| . ~/.bashrc | |
| mkdir ~/local | |
| mkdir ~/node-latest-install | |
| cd ~/node-latest-install | |
| curl http://nodejs.org/dist/node-latest.tar.gz | tar xz --strip-components=1 | |
| ./configure --prefix=~/local | |
| make install # ok, fine, this step probably takes more than 30 seconds... | |
| curl https://www.npmjs.org/install.sh | sh |
| // Functions to help figure out whether elements are in the viewport | |
| // and lazy-load their content if so. | |
| // Implemented as jQuery plugins. | |
| (function() { | |
| $.fn.inView = function(nearThreshold) { | |
| var $elem = $(this); | |
| // Checks if its visible, CSS-wise | |
| if (!$elem.is(":visible")) { | |
| return false; |
| <?php | |
| namespace my_app\models; | |
| use MongoId; | |
| use lithium\data\collection\DocumentSet; | |
| use lithium\data\entity\Document; | |
| use lithium\util\Inflector; | |
| use lithium\core\Libraries; | |
| use lithium\util\Set; |
| <?php | |
| namespace app\tests\cases\controllers; | |
| use app\tests\mocks\MockArticlesController; | |
| use app\tests\mocks\action\MockControllerRequest as Request; //Mocking the Request | |
| class ArticlesControllerTest extends \lithium\test\Unit { | |
| protected $_controller; |
| <?php | |
| use lithium\net\http\Media; | |
| /** | |
| * This re-maps your template paths so you can have stuff like `pages/users_{username}.php` | |
| * instead of the Lithium default. | |
| */ | |
| Media::type('html', 'text/html', array( | |
| 'view' => 'lithium\template\View', |