Skip to content

Instantly share code, notes, and snippets.

View atomjoy's full-sized avatar

Atomjoy atomjoy

View GitHub Profile
@atomjoy
atomjoy / Laravel-Modules.md
Last active September 1, 2026 12:03
Laravel modules in custom location with Laravel 13, Vue and Inertia.

Laravel Custom Modules

Custom modules location modules/{Module} in Laravel project.

Composer

composer.json

{
@atomjoy
atomjoy / Lead-Pipeline-Panel.html
Last active August 28, 2026 12:04
Lead pipeline panel in html, js.
<!doctype html>
<html lang="pl">
<head>
<meta charset="UTF-8" />
<title>CRM Pipeline</title>
<style>
* {
box-sizing: border-box;
margin: 0;
@atomjoy
atomjoy / fonts.css
Last active August 27, 2026 16:39
Import Poppins fonts from local server.
/*
Download fonts here:
https://fontsource.org/fonts/poppins/install
unzip all font files from static directory to fonts/poppins
More fonts:
https://www.npmjs.com/package/@fontsource/poppins
https://github.com/fontsource/font-files/tree/main/fonts/google/poppins/files
*/
@atomjoy
atomjoy / Curl-No-Cache.md
Last active August 27, 2026 15:05
Curl no-cache example.

Curl no cache

curl http://https://example.com/main.js?random
curl -H 'Pragma: no-cache' https://example.com/main.js
curl -H 'Cache-Control: no-cache' https://example.com/main.js

Curl show headers

@atomjoy
atomjoy / code-mirror-editor.css
Created August 27, 2026 14:55
CodeMirror editor style.
/* Style from curl online: https://reqbin.com/curl */
.CodeMirror {
font-family: monospace;
height: 300px;
color: black;
direction: ltr;
}
.CodeMirror-lines {
padding: 4px 0;
@atomjoy
atomjoy / Vue-Brotli-Compress.md
Last active August 26, 2026 11:32
Brotli kompresja plików z tailwind.

Brotli kompresja plików css z tailwind

W folderze produkcyjnym dist/assets/ obok standardowych plików (np. index-C3b8x2.js oraz index-B9a1x2.css) zobaczysz ich super-lekkie wersje z rozszerzeniem .br (np. index-C3b8x2.js.br).

Instalacja

Dodajesz tylko jeżeli potrzebujesz generować pliki z .br gdyż serwer nginx nie obsługuje modułu brotli.

# Vue
@atomjoy
atomjoy / Inertia-Custom-Headers.md
Last active August 25, 2026 13:49
Inertia custom headers (bearer token).

Custom Headers in Inertia, Laravel 13

Nie potrzebujesz tokenów Bearer gdy wysyłasz zapytania wyłącznie do własnych kontrolerów, powinieneś użyć uwierzytelniania opartego na ciasteczkach (Cookie-Based / Session Authentication) dostarczanego przez Laravel Sanctum.

// import WebsiteLayout from '@/layouts/website/Layout.vue';
import AppLayout from '@/layouts/AppLayout.vue';
import AuthLayout from '@/layouts/AuthLayout.vue';
import SettingsLayout from '@/layouts/settings/Layout.vue';
import { createInertiaApp } from '@inertiajs/vue3';
@atomjoy
atomjoy / Disable-Gtag-Inertia.md
Last active August 25, 2026 13:02
Disable gtag in Vue 3 z Inertia

Blokowanie gtag.js i GTM w Laravel 13 + Vue 3 (Inertia)

Dodaj w pliku app.ts na końcu.

Blokowanie GA gtag.js w Inertia

// Google Analytics id
const GA_ID = 'G-XXXXXXXXXX';
@atomjoy
atomjoy / Vue3-Inertia-FontAwesomeIcons.md
Last active August 25, 2026 12:05
Vue3 Inertia font awesome icons

Font Awesome Icons in Vue3 Inertia

Install packages...

# Translate
npm install vue-i18n@11

# Fontawesome
npm install @fortawesome/vue-fontawesome@latest-3
@atomjoy
atomjoy / table-1.html
Last active August 24, 2026 16:59
Html table
<div class="table-container">
<table>
<thead>
<tr>
<th>Nagłówek 1</th>
<th>Nagłówek 2</th>
<th>Nagłówek 3</th>
<th>Nagłówek 1</th>
<th>Nagłówek 2</th>
<th>Nagłówek 3</th>