This file contains hidden or 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\Http\Middleware; | |
use Closure; | |
use Illuminate\Http\Request; | |
use Symfony\Component\HttpFoundation\Response; | |
class SecureHeadersMiddleware | |
{ |
This file contains hidden or 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
# Redirige la ra铆z "/" a "/api" | |
RewriteCond %{REQUEST_URI} ^/$ | |
RewriteRule ^$ /api [L,R=302] |
This file contains hidden or 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
<template> | |
<div v-if="isVisible" class="fixed inset-0 flex items-center justify-center bg-black bg-opacity-50 z-50"> | |
<div class="bg-white p-6 rounded-lg shadow-lg max-w-md w-full"> | |
<h2 class="text-lg font-semibold mb-4">{{ title }}</h2> | |
<p class="mb-6">{{ message }}</p> | |
<div class="flex justify-end space-x-4"> | |
<button class="bg-gray-500 text-white py-2 px-4 rounded hover:bg-gray-600" @click="handleCancel"> | |
{{ cancelText }} | |
</button> | |
<button class="bg-blue-500 text-white py-2 px-4 rounded hover:bg-blue-600" @click="handleConfirm"> |
This file contains hidden or 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\Traits; | |
use Carbon\Carbon; | |
use DateTimeInterface; | |
use Illuminate\Database\Eloquent\Casts\Attribute; | |
trait HasFormattedDatesTrait | |
{ |
This file contains hidden or 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\Traits; | |
use Illuminate\Http\Request; | |
trait HandlesPerPageTrait | |
{ | |
/** | |
* Get the per page value from the request. |
This file contains hidden or 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
{ | |
"preset": "laravel", | |
"exclude": [ | |
"vendor" | |
] | |
} |
This file contains hidden or 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
<?xml version="1.0"?> | |
<ruleset name="Laravel Standards"> | |
<description>The Laravel Coding Standards</description> | |
<rule ref="PSR12" /> | |
<exclude-pattern>*/database/*</exclude-pattern> | |
<exclude-pattern>*/storage/*</exclude-pattern> | |
<exclude-pattern>*/vendor/*</exclude-pattern> | |
</ruleset> |
This file contains hidden or 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 | |
$finder = PhpCsFixer\Finder::create() | |
->in([ | |
__DIR__ . '/app', | |
__DIR__ . '/config', | |
__DIR__ . '/database', | |
__DIR__ . '/resources', | |
__DIR__ . '/routes', | |
__DIR__ . '/tests', |
This file contains hidden or 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
{ | |
"rules": { | |
"no-unused-vars": true, | |
"no-undef": true, | |
"no-redeclare": true, | |
"no-unreachable": true, | |
"no-console": true, | |
"no-debugger": true | |
}, | |
"ignore": [ |
This file contains hidden or 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
<script setup> | |
import {Inertia} from "@inertiajs/inertia"; | |
import {Link} from "@inertiajs/inertia-vue3"; | |
const props = defineProps({ | |
links: { | |
type: Object, | |
default: () => ({}) | |
} | |
}) |
NewerOlder