appwrite/app/config/site-templates.php

40 lines
1.1 KiB
PHP
Raw Normal View History

<?php
const TEMPLATE_FRAMEWORKS = [
'SVELTEKIT' => [
'key' => 'sveltekit',
'name' => 'SvelteKit',
2024-10-27 15:15:49 +00:00
'installCommand' => 'npm install',
'buildCommand' => 'npm run build',
'outputDirectory' => './build',
'serveRuntime' => 'node-22',
'buildRuntime' => 'node-22',
],
];
2024-10-27 15:15:49 +00:00
function getFramework(string $frameworkEnum, array $overrides)
{
2024-10-27 15:15:49 +00:00
$settings = \array_merge(TEMPLATE_FRAMEWORKS[$frameworkEnum], $overrides);
return $settings;
}
return [
[
'key' => 'starter',
2024-10-27 14:48:39 +00:00
'name' => 'Personal portfolio',
'useCases' => ['starter'],
'frameworks' => [
2024-10-27 20:49:44 +00:00
getFramework('SVELTEKIT', [
2024-10-27 15:15:49 +00:00
'serveRuntime' => 'static-1',
'installCommand' => 'npm install --force',
'providerRootDirectory' => './'
])
2024-10-25 16:04:32 +00:00
],
'vcsProvider' => 'github',
2024-10-27 14:48:39 +00:00
'providerRepositoryId' => 'portfolio-walter-o-brien',
'providerOwner' => 'adityaoberai',
'providerVersion' => '0.1.*',
2024-10-25 16:04:32 +00:00
'variables' => [],
],
];