Beispiel #1
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $asset = new self();
     $ant->register('asset', function ($path) use($asset) {
         return $asset->check($path);
     });
 }
Beispiel #2
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $thisis = $this;
     $ant->register('leaf', function (array $options = array()) use($thisis) {
         return \Undercloud\Leaf::init($options ? $options : $thisis->options);
     });
 }
Beispiel #3
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $params = isset($this->options['params']) ? $this->options['params'] : array();
     $attrs = isset($this->options['attrs']) ? $this->options['attrs'] : array();
     self::setup($params, $attrs);
     $ant->register('youtube', new self());
 }
Beispiel #4
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $ant->register('ga', function ($code, $domain = '') {
         $ga = new self();
         return $ga->embed($code, $domain);
     });
 }
Beispiel #5
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $ant->register('css', function ($storage) {
         return new \Undercloud\InlineCSS($storage);
     });
 }
Beispiel #6
0
 /**
  * Register plugin
  *
  * @param Ant\Ant $ant instance
  *
  * @return void
  */
 public function register(Ant $ant)
 {
     $ant->register('faker', \Faker\Factory::create($this->locale));
 }
Beispiel #7
0
 public function register(Ant $ant)
 {
     $ant->register('lang', new \Undercloud\Lang($this->options));
 }