<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>Laravel on Laravel: Framework de php</title>
    <link>https://web.infenlaces.com/laravel/</link>
    <description>Recent content in Laravel on Laravel: Framework de php</description>
    <generator>Hugo</generator>
    <language>es</language>
    <lastBuildDate>Mon, 12 Jan 2026 08:00:00 +0200</lastBuildDate>
    <atom:link href="https://web.infenlaces.com/laravel/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>Dashboard según rol</title>
      <link>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/02_page_role_autenticated/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/02_page_role_autenticated/</guid>
      <description>&lt;h1 id=&#34;página-user-autenticado-según-rol&#34;&gt;Página user autenticado según rol&lt;/h1&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Se pretende una vez autenticado entregar un dashboard u otro&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;En este caso tenemos 3 roles:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;admin&lt;/li&gt;&#xA;&lt;li&gt;studnet&lt;/li&gt;&#xA;&lt;li&gt;teacher&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;crear-middleware&#34;&gt;Crear middleware&lt;/h3&gt;&#xA;&lt;p&gt;Primero creamos un &lt;strong&gt;middleware&lt;/strong&gt; para que se ejecute una vez autenticado&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;  php artisan make:middleware RedirectIfAuthenticated&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&lt;/p&gt;&#xA;&lt;h3 id=&#34;el-código&#34;&gt;El código&lt;/h3&gt;</description>
    </item>
    <item>
      <title>Dashboard según rol</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/02_page_role_autenticated/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/02_page_role_autenticated/</guid>
      <description>&lt;h1 id=&#34;página-user-autenticado-según-rol&#34;&gt;Página user autenticado según rol&lt;/h1&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Se pretende una vez autenticado entregar un dashboard u otro&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;p&gt;En este caso tenemos 3 roles:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;admin&lt;/li&gt;&#xA;&lt;li&gt;studnet&lt;/li&gt;&#xA;&lt;li&gt;teacher&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;crear-middleware&#34;&gt;Crear middleware&lt;/h3&gt;&#xA;&lt;p&gt;Primero creamos un &lt;strong&gt;middleware&lt;/strong&gt; para que se ejecute una vez autenticado&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;  php artisan make:middleware RedirectIfAuthenticated&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&lt;/p&gt;&#xA;&lt;h3 id=&#34;el-código&#34;&gt;El código&lt;/h3&gt;</description>
    </item>
    <item>
      <title>Instalación</title>
      <link>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/01_instalacion/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/01_instalacion/</guid>
      <description>&lt;h1 id=&#34;instalando-fortify&#34;&gt;Instalando fortify&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Referencia en la web &lt;a href=&#34;https://laravel.com/docs/master/fortify&#34;&gt;https://laravel.com/docs/master/fortify&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Instalación&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;  composer require laravel/fortify &lt;span style=&#34;color:#228b22&#34;&gt;# Instalar el paquete&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  php artisan fortify:install &lt;span style=&#34;color:#228b22&#34;&gt;# publicar los recursos de fortify&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  php artisan migrate &lt;span style=&#34;color:#228b22&#34;&gt;# ejecutar las migraciones&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;* &lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;**Qué se ha instalado y cómo usarlo&#xA;Observamos que no se ha&#xA;&lt;strong&gt;Http/Controller&lt;/strong&gt;:&#xA;&lt;img src=&#34;img.png&#34; alt=&#34;img.png&#34;&gt;&lt;br&gt;&#xA;Por otro lado, respecto a las migracines aparece una migración que modifica la tabla &lt;strong&gt;users&lt;/strong&gt;, añadiendo los siguientes campos para la autenticaciń 2FA:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Instalación</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/01_instalacion/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/01_instalacion/</guid>
      <description>&lt;h1 id=&#34;instalando-fortify&#34;&gt;Instalando fortify&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Referencia en la web &lt;a href=&#34;https://laravel.com/docs/master/fortify&#34;&gt;https://laravel.com/docs/master/fortify&lt;/a&gt;&lt;/p&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;p&gt;Instalación&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;  composer require laravel/fortify &lt;span style=&#34;color:#228b22&#34;&gt;# Instalar el paquete&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  php artisan fortify:install &lt;span style=&#34;color:#228b22&#34;&gt;# publicar los recursos de fortify&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;  php artisan migrate &lt;span style=&#34;color:#228b22&#34;&gt;# ejecutar las migraciones&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;* &lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;**Qué se ha instalado y cómo usarlo&#xA;Observamos que no se ha&#xA;&lt;strong&gt;Http/Controller&lt;/strong&gt;:&#xA;&lt;img src=&#34;img.png&#34; alt=&#34;img.png&#34;&gt;&lt;br&gt;&#xA;Por otro lado, respecto a las migracines aparece una migración que modifica la tabla &lt;strong&gt;users&lt;/strong&gt;, añadiendo los siguientes campos para la autenticaciń 2FA:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Extracción de texto</title>
      <link>https://web.infenlaces.com/laravel/docs/07_multilenguaje/plugin_busqueda/</link>
      <pubDate>Mon, 12 Jan 2026 08:00:00 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/07_multilenguaje/plugin_busqueda/</guid>
      <description>&lt;h2 id=&#34;extracción-de-cadenas-de-traducción-en-laravel--vue&#34;&gt;Extracción de cadenas de traducción en Laravel + Vue&lt;/h2&gt;&#xA;&lt;p&gt;En proyectos &lt;strong&gt;Laravel + Vue&lt;/strong&gt;, es habitual envolver los textos traducibles con el helper:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{{ __(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;Texto a traducir&amp;#34;&lt;/span&gt;) }}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;El objetivo es &lt;strong&gt;recorrer recursivamente el proyecto&lt;/strong&gt; (Blade, PHP, JS, Vue) y generar un único fichero de traducción con el formato:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-json&#34; data-lang=&#34;json&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;&amp;#34;Texto 1 a traducir&amp;#34;&lt;/span&gt;: &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;&amp;#34;Texto 2 a traducir&amp;#34;&lt;/span&gt;: &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;opción-recomendada-laravel-json-translation-helper&#34;&gt;Opción recomendada: laravel-json-translation-helper&lt;/h3&gt;&#xA;&lt;p&gt;Este paquete permite &lt;strong&gt;escanear automáticamente&lt;/strong&gt; el proyecto y generar/actualizar los archivos JSON de traducción.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Extracción de texto</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/05_multilenguaje/plugin_busqueda/</link>
      <pubDate>Mon, 12 Jan 2026 08:00:00 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/05_multilenguaje/plugin_busqueda/</guid>
      <description>&lt;h2 id=&#34;extracción-de-cadenas-de-traducción-en-laravel--vue&#34;&gt;Extracción de cadenas de traducción en Laravel + Vue&lt;/h2&gt;&#xA;&lt;p&gt;En proyectos &lt;strong&gt;Laravel + Vue&lt;/strong&gt;, es habitual envolver los textos traducibles con el helper:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{{ __(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;Texto a traducir&amp;#34;&lt;/span&gt;) }}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;El objetivo es &lt;strong&gt;recorrer recursivamente el proyecto&lt;/strong&gt; (Blade, PHP, JS, Vue) y generar un único fichero de traducción con el formato:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-json&#34; data-lang=&#34;json&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;&amp;#34;Texto 1 a traducir&amp;#34;&lt;/span&gt;: &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;&amp;#34;Texto 2 a traducir&amp;#34;&lt;/span&gt;: &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#34;&amp;#34;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h3 id=&#34;opción-recomendada-laravel-json-translation-helper&#34;&gt;Opción recomendada: laravel-json-translation-helper&lt;/h3&gt;&#xA;&lt;p&gt;Este paquete permite &lt;strong&gt;escanear automáticamente&lt;/strong&gt; el proyecto y generar/actualizar los archivos JSON de traducción.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Anexos</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/100_anexos/model_binding/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/100_anexos/model_binding/</guid>
      <description>&lt;h1 id=&#34;route-model-binding--summary&#34;&gt;Route Model Binding — Summary&lt;/h1&gt;&#xA;&lt;h2 id=&#34;qué-es&#34;&gt;¿Qué es?&lt;/h2&gt;&#xA;&lt;p&gt;El &lt;strong&gt;Route Model Binding&lt;/strong&gt; es un mecanismo de Laravel que transforma automáticamente&#xA;un parámetro de una ruta en una &lt;strong&gt;instancia de un modelo Eloquent&lt;/strong&gt; antes de que&#xA;el controlador sea ejecutado.&lt;/p&gt;&#xA;&lt;p&gt;Ejemplo conceptual:&#xA;&lt;code&gt;/alumnos/5&lt;/code&gt; → &lt;code&gt;Alumno::findOrFail(5)&lt;/code&gt;&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;binding-implícito&#34;&gt;Binding implícito&lt;/h2&gt;&#xA;&lt;p&gt;Laravel lo aplica automáticamente si:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;El nombre del parámetro de la ruta coincide con el argumento&lt;/li&gt;&#xA;&lt;li&gt;El argumento del controlador está tipado con el modelo&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Route::&lt;span style=&#34;color:#658b00&#34;&gt;get&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;/alumnos/{alumno}&amp;#39;&lt;/span&gt;, [AlumnoController::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;, &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;show&amp;#39;&lt;/span&gt;]);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;public&lt;/span&gt; &lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;function&lt;/span&gt; &lt;span style=&#34;color:#008b45&#34;&gt;show&lt;/span&gt;(Alumno &lt;span style=&#34;color:#00688b&#34;&gt;$alumno&lt;/span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;{&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#228b22&#34;&gt;// $alumno es una instancia de Alumno&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;}&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;Si el modelo no existe → &lt;strong&gt;404 automático&lt;/strong&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Seeders en Laravel</title>
      <link>https://web.infenlaces.com/laravel/docs/08_migraciones/factory_seeder/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/08_migraciones/factory_seeder/</guid>
      <description>&lt;hr style=&#34;border-color: red; border-width: 3px;&#34;/&gt;&#xA;&#xA;&lt;h2 id=&#34;-factory-vs--seeder-esquema-conceptual&#34;&gt;🏭 Factory vs 🌱 Seeder (Esquema conceptual)&lt;/h2&gt;&#xA;&lt;h3 id=&#34;-idea-sencilla&#34;&gt;🎯 Idea sencilla&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Factory → fabrica datos&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Seeder → inserta datos en la base de datos&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-esquema-como-flujo-de-fabricación&#34;&gt;🏗 Esquema como “flujo de fabricación”&lt;/h2&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code&gt;[ Factory ]&#xA;     ↓&#xA;  Genera objetos con datos falsos&#xA;     ↓&#xA;[ Seeder ]&#xA;     ↓&#xA; Inserta esos datos en la tabla&#xA;     ↓&#xA;[ Base de Datos ]&#xA;&lt;/code&gt;&lt;/pre&gt;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-factory&#34;&gt;🏭 Factory&lt;/h2&gt;&#xA;&#xA;&lt;div class=&#34;definicion-concepto&#34;&gt;&#xA;    &lt;div class=&#34;definicion-titulo&#34;&gt;&#xA;        &#xA;        &lt;i class=&#34;fas fa-info-circle&#34; aria-hidden=&#34;true&#34;&gt;&lt;/i&gt;&#xA;        &#xA;        &lt;strong&gt;Factory&lt;/strong&gt;&#xA;    &lt;/div&gt;&#xA;&#xA;    &lt;div class=&#34;definicion-contenido&#34;&gt;&#xA;        &lt;p&gt;Es una clase que define &lt;strong&gt;cómo se construyen datos de prueba&lt;/strong&gt; para un modelo.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Pest</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/10_test/pest/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/10_test/pest/</guid>
      <description>&lt;div class=&#34;definicion-concepto&#34;&gt;&#xA;    &lt;div class=&#34;definicion-titulo&#34;&gt;&#xA;        &#xA;        &lt;i class=&#34;fas fa-info-circle&#34; aria-hidden=&#34;true&#34;&gt;&lt;/i&gt;&#xA;        &#xA;        &lt;strong&gt;Pest&lt;/strong&gt;&#xA;    &lt;/div&gt;&#xA;&#xA;    &lt;div class=&#34;definicion-contenido&#34;&gt;&#xA;        Pest es un framework de testing para PHP que utiliza PHPUnit por debajo, pero ofrece una sintaxis mucho más simple y expresiva.&#xA;    &lt;/div&gt;&#xA;&#xA;    &#xA;&lt;/div&gt;&#xA;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&lt;h1 id=&#34;-cheatsheet-de-tests-con-pest-en-laravel&#34;&gt;🧪 Cheatsheet de tests con Pest en Laravel&lt;/h1&gt;&#xA;&lt;p&gt;Esta chuleta resume cómo usar &lt;code&gt;it&lt;/code&gt;, &lt;code&gt;beforeEach&lt;/code&gt;, &lt;code&gt;Mockery&lt;/code&gt;, &lt;code&gt;$this-&amp;gt;get&lt;/code&gt;, &lt;code&gt;$this-&amp;gt;assertDatabaseHas&lt;/code&gt;, y más en Pest + Laravel.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;instalar-pest-en-el-proyecto&#34;&gt;Instalar pest en el proyecto&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;composer require pestphp/pest --dev --with-all-dependencies&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Instalar el plugin de pest para php&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt; composer &lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;require&lt;/span&gt; pestphp/pest-plugin-laravel --dev&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/li&gt;&#xA;&lt;li&gt;Crear un test:&#xA;·Esto creará un test llamado UserCourseContentServiceTest&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt; php artisan pest:test UserCourseContentServiceTest&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;-estructura-básica-de-un-archivo-de-test&#34;&gt;✅ Estructura básica de un archivo de test&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;5&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;6&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;7&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;8&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;9&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&amp;lt;?php&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;uses(Tests\TestCase::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; App\Models\User;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Illuminate\Support\Facades\Auth;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Laravel\Socialite\Facades\Socialite;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Laravel\Socialite\Contracts\User &lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;as&lt;/span&gt; SocialUserContract;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Spatie\Permission\Models\Role;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Mockery;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-reutilizar-código-con-beforeeach&#34;&gt;🔁 Reutilizar código con &lt;code&gt;beforeEach&lt;/code&gt;&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Se ejecuta &lt;strong&gt;antes de cada test&lt;/strong&gt;.&lt;/li&gt;&#xA;&lt;li&gt;Puedes usar &lt;code&gt;$this-&amp;gt;&lt;/code&gt; para compartir variables entre los bloques &lt;code&gt;it&lt;/code&gt;.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 4&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 5&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 6&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 7&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 8&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt; 9&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;10&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;11&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;12&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;13&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;14&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;15&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;beforeEach(&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;function&lt;/span&gt; () {&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;googleUser&lt;/span&gt; = Mockery::&lt;span style=&#34;color:#658b00&#34;&gt;mock&lt;/span&gt;(SocialUserContract::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;googleUser&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;getEmail&amp;#39;&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;andReturn&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;student@gmail.com&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;googleUser&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;getName&amp;#39;&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;andReturn&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;Estudiante&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$provider&lt;/span&gt; = Mockery::&lt;span style=&#34;color:#658b00&#34;&gt;mock&lt;/span&gt;(\Laravel\Socialite\Contracts\Provider::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$provider&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;stateless&amp;#39;&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;andReturnSelf&lt;/span&gt;();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$provider&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;user&amp;#39;&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;andReturn&lt;/span&gt;(&lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;googleUser&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    Socialite::&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;driver&amp;#39;&lt;/span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        -&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;with&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;google&amp;#39;&lt;/span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        -&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;andReturn&lt;/span&gt;(&lt;span style=&#34;color:#00688b&#34;&gt;$provider&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    Role::&lt;span style=&#34;color:#658b00&#34;&gt;findOrCreate&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;student&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-crear-un-test-con-it&#34;&gt;✅ Crear un test con &lt;code&gt;it(...)&lt;/code&gt;&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Cada test debe tener su descripción clara.&lt;/li&gt;&#xA;&lt;li&gt;Usa &lt;code&gt;$this-&amp;gt;get()&lt;/code&gt; para simular una petición HTTP.&lt;/li&gt;&#xA;&lt;li&gt;Usa &lt;code&gt;$this-&amp;gt;assertDatabaseHas()&lt;/code&gt; para comprobar la base de datos.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;5&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;6&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;7&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;8&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;it(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;crea un nuevo usuario estudiante con Google&amp;#39;&lt;/span&gt;, &lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;function&lt;/span&gt; () {&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;get&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;/auth/google/callback&amp;#39;&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    &lt;span style=&#34;color:#00688b&#34;&gt;$this&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;assertDatabaseHas&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;users&amp;#39;&lt;/span&gt;, [&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;email&amp;#39;&lt;/span&gt; =&amp;gt; &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;student@gmail.com&amp;#39;&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;        &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;name&amp;#39;&lt;/span&gt;  =&amp;gt; &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;Estudiante&amp;#39;&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;    ]);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;});&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-mock-de-servicios-personalizados-por-ejemplo-otp&#34;&gt;📧 Mock de servicios personalizados (por ejemplo OTP)&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#00688b&#34;&gt;$otpMock&lt;/span&gt; = Mockery::&lt;span style=&#34;color:#658b00&#34;&gt;mock&lt;/span&gt;(\App\Services\OtpService::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;);&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#00688b&#34;&gt;$otpMock&lt;/span&gt;-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;shouldReceive&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;sendOtp&amp;#39;&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;once&lt;/span&gt;();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;app()-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;instance&lt;/span&gt;(\App\Services\OtpService::&lt;span style=&#34;color:#658b00&#34;&gt;class&lt;/span&gt;, &lt;span style=&#34;color:#00688b&#34;&gt;$otpMock&lt;/span&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-validar-si-el-usuario-está-logueado&#34;&gt;🧪 Validar si el usuario está logueado&lt;/h2&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;expect(Auth::&lt;span style=&#34;color:#658b00&#34;&gt;check&lt;/span&gt;())-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;toBeTrue&lt;/span&gt;();&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;expect(Auth::&lt;span style=&#34;color:#658b00&#34;&gt;user&lt;/span&gt;()-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;email&lt;/span&gt;)-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;toBe&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;student@gmail.com&amp;#39;&lt;/span&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-llamar-directamente-a-un-controlador-en-tests&#34;&gt;🔀 Llamar directamente a un controlador en tests&lt;/h2&gt;&#xA;&lt;p&gt;Útil si quieres evitar depender de rutas.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Laravel: Uso de la Facade File</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/999_cheatseet/05_filefacade/</link>
      <pubDate>Sun, 02 Mar 2025 00:00:00 +0000</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/999_cheatseet/05_filefacade/</guid>
      <description>&lt;h1 id=&#34;laravel-uso-de-la-facade-file&#34;&gt;Laravel: Uso de la Facade File&lt;/h1&gt;&#xA;&lt;p&gt;La &lt;strong&gt;facade &lt;code&gt;File&lt;/code&gt;&lt;/strong&gt; en Laravel permite manipular archivos de manera sencilla sin necesidad de utilizar directamente funciones de PHP como &lt;code&gt;fopen&lt;/code&gt;, &lt;code&gt;fwrite&lt;/code&gt;, o &lt;code&gt;unlink&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;h2 id=&#34;importación-de-la-facade&#34;&gt;Importación de la Facade&lt;/h2&gt;&#xA;&lt;p&gt;Antes de usarla, es necesario importar la clase:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;use&lt;/span&gt; Illuminate\Support\Facades\File;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;h2 id=&#34;escribir-en-un-archivo&#34;&gt;Escribir en un Archivo&lt;/h2&gt;&#xA;&lt;p&gt;Para escribir en un archivo, usamos &lt;code&gt;File::put()&lt;/code&gt;:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;span style=&#34;background-color:#d6d6c6&#34;&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex; background-color:#d6d6c6&#34;&gt;&lt;span&gt;File::&lt;span style=&#34;color:#658b00&#34;&gt;put&lt;/span&gt;(storage_path(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;logs/laravel.log&amp;#39;&lt;/span&gt;), &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;Este es un nuevo contenido.&amp;#39;&lt;/span&gt;);&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;p&gt;Esto sobrescribe el contenido del archivo con el nuevo texto.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Laravel: Uso de la Facade File</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/999_cheatseet/06_authfortity/</link>
      <pubDate>Sun, 02 Mar 2025 00:00:00 +0000</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/999_cheatseet/06_authfortity/</guid>
      <description>&lt;h1 id=&#34;-laravel-auth-cheatsheet-facade--helpers&#34;&gt;✅ Laravel Auth Cheatsheet (Facade &amp;amp; Helpers)&lt;/h1&gt;&#xA;&lt;blockquote&gt;&#xA;&lt;p&gt;Autenticación usando el facade &lt;code&gt;Auth&lt;/code&gt; y el helper &lt;code&gt;auth()&lt;/code&gt;&lt;br&gt;&#xA;&lt;em&gt;(Válido para Laravel + Fortify)&lt;/em&gt;&lt;/p&gt;&#xA;&lt;/blockquote&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-inicio-y-cierre-de-sesión&#34;&gt;🔐 Inicio y cierre de sesión&lt;/h2&gt;&#xA;&lt;table&gt;&#xA;  &lt;thead&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;th&gt;Código&lt;/th&gt;&#xA;          &lt;th&gt;Descripción&lt;/th&gt;&#xA;      &lt;/tr&gt;&#xA;  &lt;/thead&gt;&#xA;  &lt;tbody&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::login($user)&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Inicia sesión con el usuario indicado&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::logout()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Cierra la sesión del usuario&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::attempt([&#39;email&#39; =&amp;gt; ..., &#39;password&#39; =&amp;gt; ...])&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Intenta iniciar sesión con credenciales&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;login($user)&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que &lt;code&gt;Auth::login()&lt;/code&gt; (helper)&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;logout()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que &lt;code&gt;Auth::logout()&lt;/code&gt;&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;attempt([...])&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que &lt;code&gt;Auth::attempt()&lt;/code&gt;&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;  &lt;/tbody&gt;&#xA;&lt;/table&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-acceder-al-usuario-autenticado&#34;&gt;👤 Acceder al usuario autenticado&lt;/h2&gt;&#xA;&lt;table&gt;&#xA;  &lt;thead&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;th&gt;Código&lt;/th&gt;&#xA;          &lt;th&gt;Descripción&lt;/th&gt;&#xA;      &lt;/tr&gt;&#xA;  &lt;/thead&gt;&#xA;  &lt;tbody&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::user()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Devuelve el usuario actual autenticado (o &lt;code&gt;null&lt;/code&gt;)&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;user()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que arriba&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::id()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Devuelve el ID del usuario autenticado&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;id()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que arriba&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::check()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Devuelve &lt;code&gt;true&lt;/code&gt; si hay un usuario autenticado&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;auth()-&amp;gt;check()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Igual que arriba&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;      &lt;tr&gt;&#xA;          &lt;td&gt;&lt;code&gt;Auth::guest()&lt;/code&gt;&lt;/td&gt;&#xA;          &lt;td&gt;Devuelve &lt;code&gt;true&lt;/code&gt; si &lt;strong&gt;no&lt;/strong&gt; hay usuario autenticado&lt;/td&gt;&#xA;      &lt;/tr&gt;&#xA;  &lt;/tbody&gt;&#xA;&lt;/table&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-proteger-rutas&#34;&gt;🛡️ Proteger rutas&lt;/h2&gt;&#xA;&lt;p&gt;En tu archivo &lt;code&gt;routes/web.php&lt;/code&gt;:&lt;/p&gt;</description>
    </item>
    <item>
      <title>Diagrama de flujo</title>
      <link>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/diagrama/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/diagrama/</guid>
      <description>&lt;h1 id=&#34;idea-del-diagrama&#34;&gt;Idea del Diagrama&lt;/h1&gt;&#xA;&lt;h2 id=&#34;1-configuración-inicial&#34;&gt;1. Configuración Inicial&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Archivo de Configuración &lt;code&gt;fortify.php&lt;/code&gt;&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Ruta: &lt;code&gt;config/fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Elementos configurables:&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;features&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;views&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;guard&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;passwords&lt;/code&gt;, etc.&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;username&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;email&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;lowercase_username&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;home&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;prefix&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;domain&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;middleware&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;limiters&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;2-proceso-de-autenticación&#34;&gt;2. Proceso de Autenticación&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Solicitudes de Autenticación&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Rutas de Fortify&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Registro&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/register&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Inicio de sesión&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/login&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Restablecimiento de contraseña&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/forgot-password&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;/reset-password&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores de Fortify&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;RegistersUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;AuthenticatesUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;ResetsPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;ConfirmsPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;VerifiesEmails&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;UpdatesPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;TwoFactorAuthenticatesUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;LogoutUsers&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Eventos y Acciones&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Registro exitoso&lt;/li&gt;&#xA;&lt;li&gt;Inicio de sesión exitoso&lt;/li&gt;&#xA;&lt;li&gt;Restablecimiento de contraseña exitoso&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;3-personalización&#34;&gt;3. Personalización&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores Personalizados&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Sobrescribir los controladores de Fortify&lt;/li&gt;&#xA;&lt;li&gt;Ubicación: &lt;code&gt;app/Http/Controllers/Auth&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Vistas Personalizadas&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Sobrescribir las vistas de Fortify&lt;/li&gt;&#xA;&lt;li&gt;Ubicación: &lt;code&gt;resources/views/auth&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;4-funcionalidades-adicionales&#34;&gt;4. Funcionalidades Adicionales&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Verificación de Dos Factores (2FA)&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración en &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Clases: &lt;code&gt;TwoFactorAuthenticationController&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Verificación de Correo Electrónico&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración en &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Clases: &lt;code&gt;EmailVerificationController&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;5-interacción-con-modelos&#34;&gt;5. Interacción con Modelos&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;User Model&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Métodos personalizados&lt;/li&gt;&#xA;&lt;li&gt;Relaciones con otras entidades&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;6-diagrama-general&#34;&gt;6. Diagrama General&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Componentes Principales&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración Inicial&lt;/li&gt;&#xA;&lt;li&gt;Proceso de Autenticación&lt;/li&gt;&#xA;&lt;li&gt;Personalización&lt;/li&gt;&#xA;&lt;li&gt;Funcionalidades Adicionales&lt;/li&gt;&#xA;&lt;li&gt;Interacción con Modelos&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;detalles-del-diagrama&#34;&gt;Detalles del Diagrama&lt;/h1&gt;&#xA;&lt;h2 id=&#34;a-configuración-inicial&#34;&gt;A. Configuración Inicial&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Archivo de Configuración &lt;code&gt;fortify.php&lt;/code&gt;&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Diagrama detallando las configuraciones clave y su impacto.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;b-proceso-de-autenticación&#34;&gt;B. Proceso de Autenticación&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Solicitudes de Autenticación&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Flujo desde la solicitud del usuario hasta la respuesta del servidor.&lt;/li&gt;&#xA;&lt;li&gt;Incluye rutas, controladores y vistas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;c-personalización&#34;&gt;C. Personalización&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores y Vistas Personalizadas&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Cómo sobrescribir y extender las funcionalidades de Fortify.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;d-funcionalidades-adicionales&#34;&gt;D. Funcionalidades Adicionales&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;2FA y Verificación de Correo&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Flujo y clases involucradas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;e-interacción-con-modelos&#34;&gt;E. Interacción con Modelos&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;User Model&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Métodos importantes y relaciones.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;ejemplo-de-esquema-del-diagrama&#34;&gt;Ejemplo de Esquema del Diagrama&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Nodo Central&lt;/strong&gt;: Laravel Fortify&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Subnodos&lt;/strong&gt;:&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración Inicial&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Archivo &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Proceso de Autenticación&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Rutas&lt;/li&gt;&#xA;&lt;li&gt;Controladores&lt;/li&gt;&#xA;&lt;li&gt;Eventos&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Personalización&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Controladores Personalizados&lt;/li&gt;&#xA;&lt;li&gt;Vistas Personalizadas&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Funcionalidades Adicionales&#xA;&lt;ul&gt;&#xA;&lt;li&gt;2FA&lt;/li&gt;&#xA;&lt;li&gt;Verificación de Correo&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Interacción con Modelos&#xA;&lt;ul&gt;&#xA;&lt;li&gt;User Model&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;conexiones&#34;&gt;Conexiones&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Conexiones entre nodos mostrando el flujo de datos.&lt;/li&gt;&#xA;&lt;li&gt;Anotaciones en cada conexión para describir el propósito y funcionalidad.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Con esta estructura, podrás crear un diagrama en Draw.io que ilustre claramente cómo funciona Fortify, cómo se configura y cómo se puede personalizar para ajustarse a las necesidades específicas de tu aplicación Laravel.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Diagrama de flujo</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/diagrama/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/diagrama/</guid>
      <description>&lt;h1 id=&#34;idea-del-diagrama&#34;&gt;Idea del Diagrama&lt;/h1&gt;&#xA;&lt;h2 id=&#34;1-configuración-inicial&#34;&gt;1. Configuración Inicial&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Archivo de Configuración &lt;code&gt;fortify.php&lt;/code&gt;&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Ruta: &lt;code&gt;config/fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Elementos configurables:&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;features&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;views&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;guard&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;passwords&lt;/code&gt;, etc.&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;username&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;email&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;lowercase_username&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;home&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;prefix&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;domain&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;middleware&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;limiters&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;2-proceso-de-autenticación&#34;&gt;2. Proceso de Autenticación&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Solicitudes de Autenticación&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Rutas de Fortify&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Registro&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/register&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Inicio de sesión&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/login&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Restablecimiento de contraseña&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;/forgot-password&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;/reset-password&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores de Fortify&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;code&gt;RegistersUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;AuthenticatesUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;ResetsPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;ConfirmsPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;VerifiesEmails&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;UpdatesPasswords&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;TwoFactorAuthenticatesUsers&lt;/code&gt;,&lt;/li&gt;&#xA;&lt;li&gt;&lt;code&gt;LogoutUsers&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Eventos y Acciones&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Registro exitoso&lt;/li&gt;&#xA;&lt;li&gt;Inicio de sesión exitoso&lt;/li&gt;&#xA;&lt;li&gt;Restablecimiento de contraseña exitoso&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;3-personalización&#34;&gt;3. Personalización&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores Personalizados&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Sobrescribir los controladores de Fortify&lt;/li&gt;&#xA;&lt;li&gt;Ubicación: &lt;code&gt;app/Http/Controllers/Auth&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Vistas Personalizadas&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Sobrescribir las vistas de Fortify&lt;/li&gt;&#xA;&lt;li&gt;Ubicación: &lt;code&gt;resources/views/auth&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;4-funcionalidades-adicionales&#34;&gt;4. Funcionalidades Adicionales&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Verificación de Dos Factores (2FA)&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración en &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Clases: &lt;code&gt;TwoFactorAuthenticationController&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Verificación de Correo Electrónico&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración en &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Clases: &lt;code&gt;EmailVerificationController&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;5-interacción-con-modelos&#34;&gt;5. Interacción con Modelos&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;User Model&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Métodos personalizados&lt;/li&gt;&#xA;&lt;li&gt;Relaciones con otras entidades&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;6-diagrama-general&#34;&gt;6. Diagrama General&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Componentes Principales&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración Inicial&lt;/li&gt;&#xA;&lt;li&gt;Proceso de Autenticación&lt;/li&gt;&#xA;&lt;li&gt;Personalización&lt;/li&gt;&#xA;&lt;li&gt;Funcionalidades Adicionales&lt;/li&gt;&#xA;&lt;li&gt;Interacción con Modelos&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;detalles-del-diagrama&#34;&gt;Detalles del Diagrama&lt;/h1&gt;&#xA;&lt;h2 id=&#34;a-configuración-inicial&#34;&gt;A. Configuración Inicial&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Archivo de Configuración &lt;code&gt;fortify.php&lt;/code&gt;&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Diagrama detallando las configuraciones clave y su impacto.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;b-proceso-de-autenticación&#34;&gt;B. Proceso de Autenticación&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Solicitudes de Autenticación&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Flujo desde la solicitud del usuario hasta la respuesta del servidor.&lt;/li&gt;&#xA;&lt;li&gt;Incluye rutas, controladores y vistas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;c-personalización&#34;&gt;C. Personalización&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Controladores y Vistas Personalizadas&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Cómo sobrescribir y extender las funcionalidades de Fortify.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;d-funcionalidades-adicionales&#34;&gt;D. Funcionalidades Adicionales&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;2FA y Verificación de Correo&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Flujo y clases involucradas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h2 id=&#34;e-interacción-con-modelos&#34;&gt;E. Interacción con Modelos&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;User Model&lt;/strong&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Métodos importantes y relaciones.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;ejemplo-de-esquema-del-diagrama&#34;&gt;Ejemplo de Esquema del Diagrama&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;strong&gt;Nodo Central&lt;/strong&gt;: Laravel Fortify&lt;/li&gt;&#xA;&lt;li&gt;&lt;strong&gt;Subnodos&lt;/strong&gt;:&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Configuración Inicial&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Archivo &lt;code&gt;fortify.php&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Proceso de Autenticación&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Rutas&lt;/li&gt;&#xA;&lt;li&gt;Controladores&lt;/li&gt;&#xA;&lt;li&gt;Eventos&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Personalización&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Controladores Personalizados&lt;/li&gt;&#xA;&lt;li&gt;Vistas Personalizadas&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Funcionalidades Adicionales&#xA;&lt;ul&gt;&#xA;&lt;li&gt;2FA&lt;/li&gt;&#xA;&lt;li&gt;Verificación de Correo&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;li&gt;Interacción con Modelos&#xA;&lt;ul&gt;&#xA;&lt;li&gt;User Model&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h1 id=&#34;conexiones&#34;&gt;Conexiones&lt;/h1&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Conexiones entre nodos mostrando el flujo de datos.&lt;/li&gt;&#xA;&lt;li&gt;Anotaciones en cada conexión para describir el propósito y funcionalidad.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Con esta estructura, podrás crear un diagrama en Draw.io que ilustre claramente cómo funciona Fortify, cómo se configura y cómo se puede personalizar para ajustarse a las necesidades específicas de tu aplicación Laravel.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Personalizar controladores</title>
      <link>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/peronsalizar_controladores/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/06_autenticacion/fortify/peronsalizar_controladores/</guid>
      <description>&lt;h1 id=&#34;personalización-del-proceso-de-autenticación-en-laravel-fortify&#34;&gt;Personalización del Proceso de Autenticación en Laravel Fortify&lt;/h1&gt;&#xA;&lt;h1 id=&#34;personalizar-los--controladores-para-autenticación-con-fortify&#34;&gt;Personalizar los  controladores para autenticación con fortify&lt;/h1&gt;&#xA;&lt;p&gt;Al instalar &lt;strong&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    Laravel Fortify&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;&lt;/strong&gt;, los controladores que manejan el proceso de &lt;em&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    login, registro y otras acciones de autenticación&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/em&gt; no se encuentran de forma explícita en el directorio &#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    Http\Controllers&#xA;&#xA;&lt;/span&gt;&#xA; de tu aplicación.&lt;/p&gt;&#xA;&lt;p&gt;Estos &lt;strong&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    Controladores&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;&lt;/strong&gt; están ubicados en &lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    vendor/laravel/fortify/src/Http/Controllers&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt; :&lt;/p&gt;&#xA;&lt;h2 id=&#34;estos-controladores-están-ubicados-en-vendorlaravelfortifysrchttpcontrollers&#34;&gt;Estos Controladores están ubicados en &lt;code&gt;vendor/laravel/fortify/src/Http/Controllers&lt;/code&gt;:&lt;/h2&gt;&#xA;&lt;h3 id=&#34;loguearse&#34;&gt;Loguearse&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    AuthenticatedSessionController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el inicio de sesión y cierre de sesión.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    RegisteredUserController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el registro de nuevos usuarios.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;confirmación-reseteo-de-password&#34;&gt;Confirmación, reseteo de password&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmablePasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la confirmación de contraseñas antes de realizar ciertas acciones.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmedPasswordStatusController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Proporciona el estado de la confirmación de la contraseña.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmedTwoFactorAuthenticationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la confirmación de autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    NewPasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el restablecimiento de contraseñas.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    PasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la actualización de contraseñas.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    PasswordResetLinkController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el envío de enlaces para restablecer contraseñas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;verificar-por-email&#34;&gt;Verificar por email&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    EmailVerificationNotificationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el envío de notificaciones de verificación de correo electrónico.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    EmailVerificationPromptController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Muestra la solicitud de verificación de correo electrónico.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    VerifyEmailController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la verificación de direcciones de correo electrónico.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;gestión-de-perfil&#34;&gt;Gestión de perfil&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ProfileInformationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la actualización de la información del perfil del usuario.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    RecoveryCodeController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja los códigos de recuperación para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;2fa&#34;&gt;2FA&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorAuthenticatedSessionController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la autenticación de sesiones con dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorAuthenticationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la activación y desactivación de la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorQrCodeController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Muestra el código QR para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorSecretKeyController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja las claves secretas para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Al instalar fortify los controladores que manejan el proceso de login, register y demás acciones de este paquete, no se exponen de forma explícita en el directorio &lt;strong&gt;http&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Personalizar controladores</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/peronsalizar_controladores/</link>
      <pubDate>Sat, 08 Apr 2023 18:21:47 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/06_autenticacion/fortify/peronsalizar_controladores/</guid>
      <description>&lt;h1 id=&#34;personalización-del-proceso-de-autenticación-en-laravel-fortify&#34;&gt;Personalización del Proceso de Autenticación en Laravel Fortify&lt;/h1&gt;&#xA;&lt;h1 id=&#34;personalizar-los--controladores-para-autenticación-con-fortify&#34;&gt;Personalizar los  controladores para autenticación con fortify&lt;/h1&gt;&#xA;&lt;p&gt;Al instalar &lt;strong&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    Laravel Fortify&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;&lt;/strong&gt;, los controladores que manejan el proceso de &lt;em&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    login, registro y otras acciones de autenticación&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/em&gt; no se encuentran de forma explícita en el directorio &#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    Http\Controllers&#xA;&#xA;&lt;/span&gt;&#xA; de tu aplicación.&lt;/p&gt;&#xA;&lt;p&gt;Estos &lt;strong&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    Controladores&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;&lt;/strong&gt; están ubicados en &lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;&#xA;    vendor/laravel/fortify/src/Http/Controllers&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt; :&lt;/p&gt;&#xA;&lt;h2 id=&#34;estos-controladores-están-ubicados-en-vendorlaravelfortifysrchttpcontrollers&#34;&gt;Estos Controladores están ubicados en &lt;code&gt;vendor/laravel/fortify/src/Http/Controllers&lt;/code&gt;:&lt;/h2&gt;&#xA;&lt;h3 id=&#34;loguearse&#34;&gt;Loguearse&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    AuthenticatedSessionController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el inicio de sesión y cierre de sesión.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    RegisteredUserController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el registro de nuevos usuarios.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;confirmación-reseteo-de-password&#34;&gt;Confirmación, reseteo de password&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmablePasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la confirmación de contraseñas antes de realizar ciertas acciones.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmedPasswordStatusController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Proporciona el estado de la confirmación de la contraseña.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ConfirmedTwoFactorAuthenticationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la confirmación de autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    NewPasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el restablecimiento de contraseñas.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    PasswordController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la actualización de contraseñas.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    PasswordResetLinkController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el envío de enlaces para restablecer contraseñas.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;verificar-por-email&#34;&gt;Verificar por email&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    EmailVerificationNotificationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja el envío de notificaciones de verificación de correo electrónico.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    EmailVerificationPromptController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Muestra la solicitud de verificación de correo electrónico.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    VerifyEmailController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la verificación de direcciones de correo electrónico.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;gestión-de-perfil&#34;&gt;Gestión de perfil&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    ProfileInformationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la actualización de la información del perfil del usuario.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    RecoveryCodeController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja los códigos de recuperación para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;2fa&#34;&gt;2FA&lt;/h3&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorAuthenticatedSessionController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la autenticación de sesiones con dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorAuthenticationController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja la activación y desactivación de la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorQrCodeController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Muestra el código QR para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;li&gt;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-primary&#34;&gt;&#xA;&#xA;    TwoFactorSecretKeyController&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt;&#xA;: Maneja las claves secretas para la autenticación de dos factores.&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;p&gt;Al instalar fortify los controladores que manejan el proceso de login, register y demás acciones de este paquete, no se exponen de forma explícita en el directorio &lt;strong&gt;http&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Lazy Loading con Vue &#43; Inertia</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/02_lazy/</link>
      <pubDate>Thu, 08 Aug 2024 18:24:10 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/02_lazy/</guid>
      <description>&lt;h1 id=&#34;-lazy-loading-en-vue-3--inertiajs&#34;&gt;💤 Lazy Loading en Vue 3 + Inertia.js&lt;/h1&gt;&#xA;&lt;p&gt;&lt;strong&gt;Lazy loading (carga diferida)&lt;/strong&gt; permite dividir tu frontend en partes pequeñas que se cargan &lt;strong&gt;sólo cuando se necesitan&lt;/strong&gt;, mejorando mucho el rendimiento.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-lazy-loading-de-componentes-vue&#34;&gt;⚙️ Lazy loading de componentes Vue&lt;/h2&gt;&#xA;&lt;p&gt;Evita esto:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-js&#34; data-lang=&#34;js&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#228b22&#34;&gt;// ❌ Carga directa del componente&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;import&lt;/span&gt; Dashboard from &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;@/Pages/Dashboard.vue&amp;#39;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;p&gt;Haz esto:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;5&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-js&#34; data-lang=&#34;js&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;import&lt;/span&gt; { defineAsyncComponent } from &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;vue&amp;#39;&lt;/span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;const&lt;/span&gt; Dashboard = defineAsyncComponent(() =&amp;gt;&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;import&lt;/span&gt;(&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;@/Pages/Dashboard.vue&amp;#39;&lt;/span&gt;)&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;)&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;p&gt;Usado en el template:&lt;/p&gt;</description>
    </item>
    <item>
      <title>tiempos de carga</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/03_tiempos/</link>
      <pubDate>Thu, 08 Aug 2024 18:24:10 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/03_tiempos/</guid>
      <description>&lt;h2 id=&#34;-3-usar-laravel-debugbar&#34;&gt;🧰 3. Usar Laravel Debugbar&lt;/h2&gt;&#xA;&lt;p&gt;Para ver tiempos del backend: consultas, render Blade, controladores, etc.&lt;/p&gt;&#xA;&lt;h3 id=&#34;instalación-solo-en-local&#34;&gt;Instalación (solo en local)&lt;/h3&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-bash&#34; data-lang=&#34;bash&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;composer require barryvdh/laravel-debugbar --dev&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;p&gt;Actívalo en &lt;code&gt;.env&lt;/code&gt;:&lt;/p&gt;&#xA;&lt;pre tabindex=&#34;0&#34;&gt;&lt;code class=&#34;language-dotenv&#34; data-lang=&#34;dotenv&#34;&gt;APP_DEBUG=true&#xA;DEBUGBAR_ENABLED=true&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;p&gt;Te muestra:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Tiempo total de ejecución&lt;/li&gt;&#xA;&lt;li&gt;Consultas SQL lentas&lt;/li&gt;&#xA;&lt;li&gt;Props de Inertia y su tamaño&lt;/li&gt;&#xA;&lt;li&gt;Eventos del ciclo de vida&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-4-herramientas-externas&#34;&gt;🌐 4. Herramientas externas&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://developers.google.com/web/tools/lighthouse&#34;&gt;Google Lighthouse&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://gtmetrix.com/&#34;&gt;GTmetrix&lt;/a&gt;&lt;/li&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://webpagetest.org/&#34;&gt;WebPageTest&lt;/a&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;h3 id=&#34;lighthouse-en-chrome&#34;&gt;Lighthouse en Chrome&lt;/h3&gt;&#xA;&lt;ol&gt;&#xA;&lt;li&gt;F12 → pestaña &lt;strong&gt;Lighthouse&lt;/strong&gt;&lt;/li&gt;&#xA;&lt;li&gt;Selecciona tipo de análisis (Mobile/Desktop)&lt;/li&gt;&#xA;&lt;li&gt;Ejecuta&lt;/li&gt;&#xA;&lt;li&gt;Revisa: First Contentful Paint, JS Execution Time, etc.&lt;/li&gt;&#xA;&lt;/ol&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-recomendaciones&#34;&gt;📌 Recomendaciones&lt;/h2&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;Mide siempre en modo producción (&lt;code&gt;APP_ENV=production&lt;/code&gt;)&lt;/li&gt;&#xA;&lt;li&gt;Usa &lt;code&gt;npm run build&lt;/code&gt; para tener JS optimizado&lt;/li&gt;&#xA;&lt;li&gt;Usa &lt;code&gt;php artisan optimize&lt;/code&gt; y &lt;code&gt;config:cache&lt;/code&gt;&lt;/li&gt;&#xA;&lt;li&gt;Usa lazy loading donde puedas&lt;/li&gt;&#xA;&lt;li&gt;Reduce props innecesarias en &lt;code&gt;Inertia::share()&lt;/code&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;p&gt;¿Quieres que prepare también una guía para detectar &lt;strong&gt;props pesadas en Inertia&lt;/strong&gt; y cómo optimizarlas?&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cómo detectar y optimizar props pesadas en Inertia.js</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/04_props_pesadas/</link>
      <pubDate>Thu, 08 Aug 2024 18:26:00 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/04_props_pesadas/</guid>
      <description>&lt;h1 id=&#34;-cómo-detectar-y-optimizar-props-pesadas-en-inertiajs&#34;&gt;📦 Cómo detectar y optimizar props pesadas en Inertia.js&lt;/h1&gt;&#xA;&lt;p&gt;Inertia permite compartir datos desde Laravel al frontend, pero enviar &lt;strong&gt;demasiada información&lt;/strong&gt; como props puede &lt;strong&gt;ralentizar&lt;/strong&gt; tu aplicación.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-problema-común&#34;&gt;❗ Problema común&lt;/h2&gt;&#xA;&lt;p&gt;En el middleware o en cada controlador puedes estar haciendo:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;1&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;2&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;3&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;4&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;5&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;6&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;7&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;8&#xA;&lt;/span&gt;&lt;span style=&#34;white-space:pre;-webkit-user-select:none;user-select:none;margin-right:0.4em;padding:0 0.4em 0 0.4em;color:#7f7f7f&#34;&gt;9&#xA;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;Inertia::&lt;span style=&#34;color:#658b00&#34;&gt;share&lt;/span&gt;([&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;auth&amp;#39;&lt;/span&gt; =&amp;gt; [&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;user&amp;#39;&lt;/span&gt; =&amp;gt; Auth::&lt;span style=&#34;color:#658b00&#34;&gt;user&lt;/span&gt;(),&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;roles&amp;#39;&lt;/span&gt; =&amp;gt; Auth::&lt;span style=&#34;color:#658b00&#34;&gt;user&lt;/span&gt;()?-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;roles&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;permissions&amp;#39;&lt;/span&gt; =&amp;gt; Auth::&lt;span style=&#34;color:#658b00&#34;&gt;user&lt;/span&gt;()?-&amp;gt;&lt;span style=&#34;color:#658b00&#34;&gt;permissions&lt;/span&gt;,&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;],&#xA;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;config&amp;#39;&lt;/span&gt; =&amp;gt; Config::&lt;span style=&#34;color:#658b00&#34;&gt;all&lt;/span&gt;(), &lt;span style=&#34;color:#228b22&#34;&gt;// ❌ Cuidado con esto&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;projects&amp;#39;&lt;/span&gt; =&amp;gt; Project::&lt;span style=&#34;color:#658b00&#34;&gt;all&lt;/span&gt;(), &lt;span style=&#34;color:#228b22&#34;&gt;// ❌ Puede ser muy pesado&#xA;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;]);&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&lt;p&gt;Eso puede generar respuestas enormes que se envían en &lt;strong&gt;cada visita&lt;/strong&gt;.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Cargar datos desde Vue con Fetch o Axios (Inertia)</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/05_carga_datos_axios/</link>
      <pubDate>Thu, 08 Aug 2024 18:27:00 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/31_optimizacion_carga/05_carga_datos_axios/</guid>
      <description>&lt;h1 id=&#34;-cargar-datos-desde-vue-con-fetch-o-axios-inertiajs&#34;&gt;🌐 Cargar datos desde Vue con Fetch o Axios (Inertia.js)&lt;/h1&gt;&#xA;&lt;p&gt;Cuando los datos son &lt;strong&gt;muy grandes&lt;/strong&gt; o cambian frecuentemente, es mejor &lt;strong&gt;no enviarlos como props&lt;/strong&gt; con Inertia y en su lugar, &lt;strong&gt;consultarlos desde el frontend&lt;/strong&gt; usando &lt;code&gt;fetch&lt;/code&gt; o &lt;code&gt;axios&lt;/code&gt;.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-por-qué-hacerlo-así&#34;&gt;❓ ¿Por qué hacerlo así?&lt;/h2&gt;&#xA;&lt;p&gt;Enviar grandes cantidades de datos como props (por ejemplo, &lt;code&gt;Project::all()&lt;/code&gt;) hace que:&lt;/p&gt;&#xA;&lt;ul&gt;&#xA;&lt;li&gt;El tiempo de carga aumente&lt;/li&gt;&#xA;&lt;li&gt;La respuesta JSON de Inertia sea pesada&lt;/li&gt;&#xA;&lt;li&gt;Sea difícil hacer filtros/paginación en frontend&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;-solución-usar-fetch-o-axios-desde-vue&#34;&gt;✅ Solución: usar &lt;code&gt;fetch()&lt;/code&gt; o &lt;code&gt;axios&lt;/code&gt; desde Vue&lt;/h2&gt;&#xA;&lt;p&gt;En lugar de pasar los datos con Inertia:&lt;/p&gt;</description>
    </item>
    <item>
      <title>swagger</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/10_api/4.-swagger/</link>
      <pubDate>Mon, 03 Mar 2025 00:00:00 +0000</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/10_api/4.-swagger/</guid>
      <description>&lt;div class=&#34;highlight&#34;&gt;&lt;div style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&#xA;&lt;table style=&#34;border-spacing:0;padding:0;margin:0;border:0;&#34;&gt;&lt;tr&gt;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&#xA;&lt;td style=&#34;vertical-align:top;padding:0;margin:0;border:0;;width:100%&#34;&gt;&#xA;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;display:grid;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;&#xA;&lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&#xA;&#xA;&#xA;&#xA;&lt;div style=&#34;border: 1px solid navy; border-radius: 5px; overflow: hidden;&#34;&gt;&#xA;    &lt;div style=&#34;background-color: navy; color: white;&#xA;    font-weight: bold; padding: 10px; display: flex; align-items: center;&#34;&gt;&#xA;        &#xA;        &lt;span style=&#34;margin-right: 8px;&#34;&gt;&#xA;            &#xA;                &lt;i class=&#34;fas fa-book&#34;&gt;&lt;/i&gt; &#xA;            &#xA;        &lt;/span&gt;&#xA;        &#xA;        &lt;span&gt;Referencias&lt;/span&gt;&#xA;    &lt;/div&gt;&#xA;&#xA;    &lt;h3 style=&#34;padding: 5px; font-weight: bold; color: navy;&#34;&gt;Fuentes de Información&lt;/h3&gt;&#xA;&#xA;    &lt;hr style=&#34;border-color: lightblue; border-width: 3px&#34;/&gt;&#xA;    &#xA;    &lt;div style=&#34;background-color: #e0f7fa; color: navy; padding: 10px;&#34;&gt;&#xA;        &lt;ul&gt;&#xA;            &#xA;            &lt;li&gt;&lt;ul&gt;&#xA;&lt;li&gt;&lt;a href=&#34;https://github.com/DarkaOnLine/L5-Swagger/wiki&#34;&gt;https://github.com/DarkaOnLine/L5-Swagger/wiki&lt;/a&gt;&lt;/li&gt;&#xA;&lt;/ul&gt;&#xA;&lt;/li&gt;&#xA;            &#xA;            &#xA;            &#xA;        &lt;/ul&gt;&#xA;    &lt;/div&gt;&#xA;&lt;/div&gt;&#xA;&#xA;&lt;h1 id=&#34;swagger-en-laravel-11&#34;&gt;Swagger en Laravel 11&lt;/h1&gt;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&lt;h2 id=&#34;introducción&#34;&gt;Introducción&lt;/h2&gt;&#xA;&lt;p&gt;&#xA;&#xA;&lt;strong&gt;&#xA;&lt;span class=&#34;font-weight-bold text-accent fs-1.5&#34;&gt;&#xA;&#xA;    Swagger (OpenAPI)&#xA;&#xA;&#xA;&lt;/span&gt;&#xA;&lt;/strong&gt; es una herramienta que permite documentar APIs de manera estructurada y visual, facilitando su uso por parte de desarrolladores y otros sistemas.&lt;/p&gt;</description>
    </item>
    <item>
      <title>Navegación</title>
      <link>https://web.infenlaces.com/laravel/docs/pendiente/14_filament/panel/panel/</link>
      <pubDate>Thu, 08 Aug 2024 18:23:50 +0200</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/pendiente/14_filament/panel/panel/</guid>
      <description>&lt;h1 id=&#34;navegación-en-el-panel&#34;&gt;Navegación en el panel&lt;/h1&gt;&#xA;&lt;p&gt;En el panel de administración de Filament, la &lt;strong&gt;navegación&lt;/strong&gt; es el conjunto de menús y botones que nos permiten acceder a los &lt;strong&gt;recursos&lt;/strong&gt;, &lt;strong&gt;páginas&lt;/strong&gt; o &lt;strong&gt;clústeres&lt;/strong&gt; que hemos creado.&lt;/p&gt;&#xA;&lt;p&gt;Filament nos permite &lt;strong&gt;organizar y personalizar&lt;/strong&gt; cómo se muestran estos elementos en el panel.&lt;/p&gt;&#xA;&lt;hr&gt;&#xA;&lt;h2 id=&#34;agrupar-recursos-con-navigationgroup&#34;&gt;Agrupar recursos con $navigationGroup&lt;/h2&gt;&#xA;&lt;p&gt;La forma más sencilla de agrupar recursos es mediante el atributo:&lt;/p&gt;&#xA;&lt;div class=&#34;highlight&#34;&gt;&lt;pre tabindex=&#34;0&#34; style=&#34;background-color:#eed;-moz-tab-size:4;-o-tab-size:4;tab-size:4;-webkit-text-size-adjust:none;&#34;&gt;&lt;code class=&#34;language-php&#34; data-lang=&#34;php&#34;&gt;&lt;span style=&#34;display:flex;&#34;&gt;&lt;span&gt;&lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;protected&lt;/span&gt; &lt;span style=&#34;color:#8b008b;font-weight:bold&#34;&gt;static&lt;/span&gt; ?string &lt;span style=&#34;color:#00688b&#34;&gt;$navigationGroup&lt;/span&gt; = &lt;span style=&#34;color:#cd5555&#34;&gt;&amp;#39;Usuarios&amp;#39;&lt;/span&gt;;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;&#xA;&lt;p&gt;O bien, con un método dinámico que incluso se puede traducir:&lt;/p&gt;</description>
    </item>
    <item>
      <title></title>
      <link>https://web.infenlaces.com/laravel/docs/08_migraciones/_index_old%C3%A7/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>https://web.infenlaces.com/laravel/docs/08_migraciones/_index_old%C3%A7/</guid>
      <description>&lt;h2 id=&#34;description-generación-y-carga-de-datos-de-prueba-mediante-factories-y-seeders-en-laravel&#34;&gt;title: &amp;ldquo;Factories y Seeders en Laravel&amp;rdquo;&#xA;date: date: 2023-04-08T18:21:47+02:00&#xA;draft: true&#xA;weight: 20&#xA;icon: fa-solid fa-seedling&#xA;description: &amp;ldquo;Generación y carga de datos de prueba mediante Factories y Seeders en Laravel.&amp;rdquo;&lt;/h2&gt;&#xA;&#xA;&#xA;&lt;div class=&#34;pageinfo pageinfo-primary&#34;&gt;&#xA;&lt;h4 id=&#34;qué-son-las-migraciones&#34;&gt;Qué son las migraciones&lt;/h4&gt;&#xA;&lt;hr&gt;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&lt;pre&gt;&lt;code&gt;Una migración en Laravel&#xA;&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&lt;pre&gt;&lt;code&gt;crear y modificar la estructura de la base de datos&#xA;&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&lt;pre&gt;&lt;code&gt;agregar, modificar y/o eliminar tablas y columnas&#xA;&lt;/code&gt;&lt;/pre&gt;&#xA;&lt;!-- raw HTML omitted --&gt;&#xA;&#xA;&lt;/div&gt;&#xA;&#xA;&#xA;&#xA;&lt;div class=&#34;pageinfo pageinfo-primary&#34;&gt;&#xA;&lt;h4 id=&#34;ubicacion-de-las-migraciones&#34;&gt;Ubicacion de las migraciones&lt;/h4&gt;&#xA;&lt;hr&gt;&#xA;&lt;p&gt;&lt;img src=&#34;img.png&#34; alt=&#34;img.png&#34;&gt;&lt;/p&gt;</description>
    </item>
    <item>
      <title>Search Results</title>
      <link>https://web.infenlaces.com/laravel/search/</link>
      <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate>
      <guid>https://web.infenlaces.com/laravel/search/</guid>
      <description></description>
    </item>
  </channel>
</rss>
