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
// Normal action creator | |
function selectChart(chartId) { | |
return { | |
type: 'SELEcT_CHART', | |
id: chartId | |
} | |
} | |
dispatch(selectChart(5)) |
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
version: '3.1' | |
services: | |
wordpress: | |
image: wordpress | |
restart: always | |
ports: | |
- 8080:80 | |
environment: | |
WORDPRESS_DB_PASSWORD: example | |
volumes: |
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
// Write some awesome Swift code, or import libraries like "Foundation", | |
// "Dispatch", or "Glibc" | |
// myProp as a required member variable with default of 0 | |
struct MyStruct1 { | |
var myProp: Double = 0 | |
} | |
let s1 = MyStruct1() |
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 Application\Search; | |
use Application\Model\Repository\BillRepositoryInterface; | |
use Application\Model\Repository\BillProfileRepositoryInterface; | |
class BillSearchResultBillProfileKeywordsDecorator implements BillSearchResultDecoratorInterface | |
{ | |
protected $profileIds = []; |
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 | |
interface OptionalFieldInterface | |
{ | |
public function getName(); | |
public function getValue(); | |
} | |
class OptionalField implements OptionalFieldInterface | |
{ |
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
GET /ksefocus_bglassman/bill/_search | |
{ | |
"query": { | |
"terms": { | |
"categories": [ | |
31, 33, 35, 36, 39, 40, 44, 45 | |
] | |
} | |
}, | |
"aggs": { |
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 | |
$loader = require_once __DIR__.'/app/bootstrap.php.cache'; | |
require_once __DIR__.'/app/AppKernel.php'; | |
$kernel = new AppKernel('dev', true); | |
$kernel->loadClassCache(); | |
$kernel->boot(); | |
$container = $kernel->getContainer(); | |
$validator = $container->get('validator'); |
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 | |
function index_by(array $arr, $getKey) { | |
return array_combine(array_map($getKey, $arr), $arr); | |
} | |
$emails = ['ben@vtdesignworks.com', 'bruce@ksefocus.com']; | |
$emailAddresses = $emailAddressRepository->findByEmails($emails); | |
$emailAddressesByEmail = index_by( | |
$emailAddresses, |
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 | |
// This is output <input type="email" /> | |
$builder->add('email', 'email'); | |
// This is output <input type="text" /> | |
$builder->add('email', null); | |
// This is output <input type="tel" /> | |
$builder->add('phone', null, array( |
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 | |
class MyTest | |
{ | |
public function testSomething() | |
{ | |
$crawler = $this->request('/foo'); | |
$form = $this->findFormByButtonText('Save'); | |
$data = array( |
NewerOlder