sveltekit-php-backend Svelte Themes

Sveltekit Php Backend

Composer package for supporting vite-plugin-sveltekit-php-backend.

PHP Backend for SvelteKit

You can have PHP logic directly in SvelteKit route directory like this: +page.server.php

<?php
function load($event) {
    $name = ($event->params['name'] ?? 'unknownn');
    return [
        'message' => "Hello " . $name,
    ];
}

Installation

See https://github.com/basuke/vite-plugin-sveltekit-php-backend

License

MIT

Top categories

Loading Svelte Themes