This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from 'react' | |
import { Route, Link } from 'react-router-dom' | |
const TabLink = ({ to, exact, title }) => ( | |
<Route path={to} exact={exact} children={({ match }) => ( | |
<li className={`nav-item ${match ? 'active' : ''}`}> | |
<Link to={to} className='nav-link' role='tab'>{title}</Link> | |
</li> | |
)} /> | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Container { | |
constructor () { | |
this._definitions = {} | |
} | |
register (id, func, factory = false) { | |
if (typeof func !== 'function') { | |
throw new Error('Invalid service function.') | |
} | |
this._definitions[id] = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"companies": [ | |
{ | |
"id": "1", | |
"created_at": "2013-12-09 00:57:49", | |
"updated_at": "2013-12-09 00:57:49", | |
"name": "Acme Corp", | |
"links": { | |
"tasks": "/companies/1/tasks", | |
"people": "/companies/1/people" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace YourCompany\YourProject\UserBundle\Controller; | |
use Symfony\Component\HttpFoundation\RedirectResponse; | |
use Symfony\Component\HttpFoundation\Request; | |
use FOS\UserBundle\Controller\SecurityController as BaseController; | |
class SecurityController extends BaseController | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
## Begin Server manifest | |
if $server_values == undef { | |
$server_values = hiera('server', false) | |
} | |
# Ensure the time is accurate, reducing the possibilities of apt repositories | |
# failing for invalid certificates | |
include '::ntp' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- | |
vagrantfile-local: | |
vm: | |
box: debian-wheezy72-x64-vbox43 | |
box_url: 'http://box.puphpet.com/debian-wheezy72-x64-vbox43.box' | |
hostname: null | |
network: | |
private_network: 12.12.12.12 | |
forwarded_port: | |
cPYJvJD3If7Q: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[CUSTOM] | |
error_reporting=-1 | |
session.save_path=/var/lib/php/session | |
date.timezone=America/Chicago | |
display_errors=true | |
[XDEBUG] | |
xdebug.remote_connect_back=0 | |
xdebug.default_enable=1 | |
xdebug.remote_autostart=0 | |
xdebug.remote_enable=0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
security: | |
encoders: | |
MyCompany\MyProject\UserBundle\Entity\User: | |
algorithm: sha1 | |
encode_as_base64: false | |
iterations: 1 | |
role_hierarchy: | |
ROLE_ADMIN: ROLE_USER | |
ROLE_SUPER_ADMIN: [ROLE_USER, ROLE_ADMIN, ROLE_ALLOWED_TO_SWITCH] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$obj = new \stdClass; | |
$obj->x = ''; | |
$gen1 = function() use ($obj) { | |
$obj->x .= ' 1 '; | |
yield; | |
$obj->x .= ' 2 '; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace Acme\DemoBundle\Controller; | |
use Symfony\Bundle\FrameworkBundle\Controller\Controller; | |
use Symfony\Component\HttpFoundation\RedirectResponse; | |
use Acme\DemoBundle\Form\ContactType; | |
// these import the "@Route" and "@Template" annotations | |
use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; |