Skip to content

Instantly share code, notes, and snippets.

View jwalton512's full-sized avatar

Jason Walton jwalton512

View GitHub Profile
@jwalton512
jwalton512 / .editorconfig
Created May 16, 2016 06:48
Default EditorConfig
root = true
[*]
indent_style = space
indent_size = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
--start with (in insert mode):
foo bar baz |beep boop beep
-- would like to end up with (without leaving insert mode:
foo bar baz
|
beep boop beep
@jwalton512
jwalton512 / gulpfile.js
Created June 4, 2015 14:25
elixir+less+scripts+browserify+version
elixir(function (mix) {
mix.less('app.less')
.less('admin.less')
.scripts(['libs/**/*.js', 'app/**/**/*.js'], 'resources/assets/build/app.js')
.browserify('app.js', 'public/js/app.js', 'resources/assets/build')
.version('js/app.js')
});
@jwalton512
jwalton512 / LogRequest.php
Created November 20, 2016 13:31
Request logging middleware
<?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Support\Facades\Log;
class LogRequest
{
protected $dontLog = ['password', 'password_confirmation'];
append
break
can
cannot
component
continue
choice
each
else
elsecan
@jwalton512
jwalton512 / admin(v2).js
Last active May 15, 2018 19:41
Harmony with Laravel + Vue + Vue Router
// dashboard component
var dashboard = Vue.extend({
template: '<p>Hello from dashboard</p>'
})
// user management component
var user = Vue.extend({
template: '<p>Hello from user management page</p>'
})
@jwalton512
jwalton512 / .php-cs-fixer.php
Last active November 8, 2021 23:50 — forked from laravel-shift/.php-cs-fixer.php
PHP CS Fixer - Laravel Coding Style Ruleset (PHP CS Fixer v3)
<?php
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
$rules = [
'array_syntax' => ['syntax' => 'short'],
'binary_operator_spaces' => [
'default' => 'single_space',
'operators' => ['=>' => null],
@jwalton512
jwalton512 / Api\Admin\TestCase.php
Created August 9, 2015 08:46
Api Testing With Laravel 5.1 (jwt-auth)
<?php
namespace Tests\Api;
use App\User;
use Tests\TestCase as BaseTestCase;
use Illuminate\Contracts\Auth\Authenticatable as UserContract;
class TestCase extends BaseTestCase
{