Skip to content

Instantly share code, notes, and snippets.

Michaël Gallego bakura10

Block or report user

Report or block bakura10

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:98b0b8014bcc980315cc
<header class="header" role="banner">
<div class="header__wrapper">
<!-- Le plus "logique" serait "header__item__sidebar-toggle" mais c'est trop lourd. J'ai aussi pensé à créer un
nouveau "contexte" et faire header-item__sidebar-toggle mais je trouvais ça illogique d'avoir header__item et header-item
sur le même élément !-->
<div class="header__item header__item__sidebar-toggle">
<a href="#"></a>
View gist:361c80543dc2bea24035
private function convertToZfResponse(ResponseInterface $response)
$zfResponse = new HttpResponse();
$zfResponse->setContent((string) $response->getBody());
foreach ($response->getHeaders() as $name => $values) {
$zfResponse->getHeaders()->addHeaderLine($name, implode(", ", $values));
View gist:8114f4e6a8384778ffc0
.new-products {
background-color: $index-newest-products-background;
.product-list {
.grid-item {
@include grid($index-newest-products-items-per-row, $index-newest-products-horizontal-gutter, $index-newest-products-vertical-gutter);
.index-section-title {
View bar.scss
.newest-products {
.products-list {
.grid-item {
@include grid($home-items-per-row, $home-horizontal-gutter, $home-vertical-gutter);
.price {
color: red; // Ceci ne s'applique que pour le .price contenu dans .newest-products
View foo.scss
.search {
.products-list {
.grid-item {
@include grid($collection-items-per-row, $collection-horizontal-gutter, $collection-vertical-gutter);
.products-list {
View aggregateService
class UserRegistrationService
private $em;
private $service1;
private $service2;
View foo.php
class UserController
* @var EntityManagerInterface
private $entityManager;
public function create()
View test.php
class Foo
public function myMethod()
$myData = [];
// MyData is filled with approximately 50-500 elements, but with a lot of attributes inside each element.
// BUT one of the property inside each element is an iterator. Therefore each element looks a bit like this:
View media-queries.scss
// ------------------------
// Organization n°1: put all the media queries at the end of the stylesheet
// ------------------------
.rule1 {
width: 100%;
h1 {
color: red;
View deploy.php
use Aws\Common\Aws;
const AWS_ACCESS_KEY = '';
const AWS_SECRET_KEY = '';
const AWS_REGION = 'us-east-1';
const S3_BUCKET = '';
You can’t perform that action at this time.