mirror of
https://github.com/appwrite/appwrite.git
synced 2026-05-26 13:51:13 +00:00
Add more defaults to frameworks
This commit is contained in:
@@ -28,12 +28,6 @@ class Framework extends Model
|
||||
'default' => '',
|
||||
'example' => 'sveltekit.png',
|
||||
])
|
||||
->addRule('defaultServeRuntime', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default runtime version.',
|
||||
'default' => '',
|
||||
'example' => 'static-1',
|
||||
])
|
||||
->addRule('serveRuntimes', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'List of supported runtime versions.',
|
||||
@@ -41,12 +35,6 @@ class Framework extends Model
|
||||
'example' => 'static-1',
|
||||
'array' => true,
|
||||
])
|
||||
->addRule('defaultBuildRuntime', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default runtime version.',
|
||||
'default' => '',
|
||||
'example' => 'node-22',
|
||||
])
|
||||
->addRule('buildRuntimes', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'List of supported runtime versions.',
|
||||
@@ -54,6 +42,36 @@ class Framework extends Model
|
||||
'example' => 'node-21.0',
|
||||
'array' => true,
|
||||
])
|
||||
->addRule('defaultServeRuntime', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default runtime version.',
|
||||
'default' => '',
|
||||
'example' => 'static-1',
|
||||
])
|
||||
->addRule('defaultBuildRuntime', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default runtime version.',
|
||||
'default' => '',
|
||||
'example' => 'node-22',
|
||||
])
|
||||
->addRule('defaultInstallCommand', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default command to download dependencies.',
|
||||
'default' => '',
|
||||
'example' => 'npm install',
|
||||
])
|
||||
->addRule('defaultBuildCommand', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default command to build site into output directory.',
|
||||
'default' => '',
|
||||
'example' => 'npm run build',
|
||||
])
|
||||
->addRule('defaultOutputDirectory', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Default output directory of build.',
|
||||
'default' => '',
|
||||
'example' => './dist',
|
||||
])
|
||||
;
|
||||
}
|
||||
|
||||
|
||||
@@ -10,18 +10,18 @@ class TemplateFramework extends Model
|
||||
public function __construct()
|
||||
{
|
||||
$this
|
||||
->addRule('key', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Parent framework key.',
|
||||
'default' => '',
|
||||
'example' => 'sveltekit',
|
||||
])
|
||||
->addRule('name', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Framework Name.',
|
||||
'default' => '',
|
||||
'example' => 'SvelteKit'
|
||||
])
|
||||
->addRule('key', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Parent framework key.',
|
||||
'default' => '',
|
||||
'example' => 'sveltekit',
|
||||
])
|
||||
->addRule('name', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'Framework Name.',
|
||||
'default' => '',
|
||||
'example' => 'SvelteKit'
|
||||
])
|
||||
->addRule('installCommand', [
|
||||
'type' => self::TYPE_STRING,
|
||||
'description' => 'The install command used to install the dependencies.',
|
||||
|
||||
Reference in New Issue
Block a user