laravel pure

This commit is contained in:
Andras Bacsai
2025-10-02 11:09:56 +02:00
parent 843713fa1b
commit fc1fd888fd
272 changed files with 24588 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
import { InertiaLinkProps } from '@inertiajs/vue3';
import { clsx, type ClassValue } from 'clsx';
import { twMerge } from 'tailwind-merge';
export function cn(...inputs: ClassValue[]) {
return twMerge(clsx(inputs));
}
export function urlIsActive(
urlToCheck: NonNullable<InertiaLinkProps['href']>,
currentUrl: string,
) {
return toUrl(urlToCheck) === currentUrl;
}
export function toUrl(href: NonNullable<InertiaLinkProps['href']>) {
return typeof href === 'string' ? href : href?.url;
}