Skip to main content

sv create

sv createは、追加機能の設定オプションを含む新しいSvelteKitプロジェクトをセットアップします。

使用方法

npx sv create [options] [path]

オプション

--from-playground <url>

Create a SvelteKit project from a playground URL. This downloads all playground files, detects external dependencies, and sets up a complete SvelteKit project structure with everything ready to go.

Example:

npx sv create --from-playground="https://svelte.dev/playground/hello-world"

--template <name>

使用するプロジェクトテンプレート:

  • minimal — 新しいアプリのための最小限のスキャフォールディング
  • demo — JavaScript無しで動作するワード推測ゲームを備えたデモアプリ
  • library — Svelteライブラリのためのテンプレートで、svelte-packageでセットアップされています

--types <option>

プロジェクトに型チェックを追加するかどうか、またその方法:

  • ts.tsファイルをデフォルトとし、.svelteコンポーネントに対してlang="ts"を使用
  • jsdocJSDoc構文を使用して型を記述

--no-types

型チェックの追加を防ぎます。推奨されません!

--add [add-ons...]

Add add-ons to the project in the create command. Following the same format as sv add.

Example:

npx sv create --add eslint prettier [path]

--no-add-ons

対話型のアドオンプロンプト無しでコマンドを実行

--install <package-manager>

パッケージマネージャーを指定して依存関係(dependencies) のインストールを行います:

  • npm
  • pnpm
  • yarn
  • bun
  • deno

--no-install

依存関係のインストールを行いません。

--no-dir-check

Skip checking whether the target directory is empty.

Edit this page on GitHub llms.txt