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 | |
declare(strict_types=1); | |
namespace ApiPlatform\Workflow\PathResolver; | |
use ApiPlatform\Core\PathResolver\OperationPathResolverInterface; | |
final class OperationPathResolver implements OperationPathResolverInterface | |
{ |
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 Components; | |
use Symfony\Component\Finder\Finder; | |
$loader = require './vendor/autoload.php'; | |
$namespace = 'ApiPlatform'; | |
$prefix = 'api-platform'; | |
$lnamespace = strlen($namespace); |
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
local NoDistraction = { enabled = 0 } | |
NoDistraction.enable = function() | |
NoDistraction.enabled = 1 | |
vim.cmd([[ | |
set noshowmode | |
set noruler | |
set laststatus=0 | |
set noshowcmd | |
set nonumber |
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
//Adapted from http://skeena.net/htmltobb/ | |
var htmlToBBCode = function(html) { | |
html = html.replace(/<pre(.*?)>(.*?)<\/pre>/gmi, "[code]$2[/code]"); | |
html = html.replace(/<h[1-7](.*?)>(.*?)<\/h[1-7]>/, "\n[h]$2[/h]\n"); | |
//paragraph handling: | |
//- if a paragraph opens on the same line as another one closes, insert an extra blank line |
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 | |
// --- | |
// slug: use-doctrine-orm-filters | |
// name: Use Doctrine Filters | |
// position: 14 | |
// executable: true | |
// --- | |
// Doctrine ORM features [a filter system](http://docs.doctrine-project.org/projects/doctrine-orm/en/latest/reference/filters.html) that allows the developer to add SQL to the conditional clauses of queries, regardless of the place where the SQL is generated (e.g. from a DQL query, or by loading associated entities). | |
// |
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 file is part of the API Platform project. | |
* | |
* (c) Kévin Dunglas <dunglas@gmail.com> | |
* | |
* For the full copyright and license information, please view the LICENSE | |
* file that was distributed with this source code. | |
*/ |
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 App\Identifier; | |
use App\Entity\User; | |
use Ramsey\Uuid\UuidInterface; | |
use Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException; | |
use Symfony\Component\Security\Core\Security; | |
use Symfony\Component\Serializer\Normalizer\DenormalizerInterface; |
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 Fry; | |
use JsonStreamingParser\Listener; | |
/** | |
* This implementation allows to process an object at a specific level | |
* when it has been fully parsed | |
*/ | |
class ObjectListener implements Listener | |
{ |
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 { Inject, Injectable, InjectionToken } from '@angular/core'; | |
import { HttpClient } from '@angular/common/http'; | |
import { Logger, LogglyConfiguration, LOGGLY_CONFIG } from '@partenariat/logger'; | |
@Injectable() | |
export class AngularLogglyLogger extends Logger { | |
constructor(http: HttpClient, @Inject(LOGGLY_CONFIG) configuration: LogglyConfiguration) { | |
super(http, configuration); | |
} | |
} |
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 Soyuka\Marsh\Tests; | |
$a = []; | |
for ($i=0; $i < 10000; $i++) { | |
$o = new \stdClass(); | |
$o->i = $i; | |
$a[] = $o; |
NewerOlder