basuke/sveltekit-php-backend

Supplemental package to support SvelteKit PHP Backend Vite Plugin

1.0.0 2023-05-21 17:15 UTC

This package is auto-updated.

Last update: 2024-11-21 20:53:58 UTC


README

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