package
Interactive CLI for create @QwikDev/astro projects.
npm install @qwikdev/create-astroGitHub-flavored package documentation.
Across all versions.
Download trend unavailable.
Runtime metadata.
Tagged topics.
Seamlessly scaffold content-driven web projects with the power of QwikDev/Astro. Whether you're building blazing-fast blogs, portfolios, or scalable applications, this CLI has you covered.
If you already have an existing Astro project and want to add the integration, you can do so with the following command:
npm create @qwikdev/astro@latest --addTo create a brand new project, you can use the following command:
npm create @qwikdev/astro@latestRun the following command using your preferred package manager:
With NPM:
npm create @qwikdev/astro@latest [destination] [adapter] [...options]With Yarn:
yarn create @qwikdev/astro [destination] [adapter] [...options]With PNPM:
pnpm create @qwikdev/astro [destination] [adapter] [...options]With Bun:
bun create @qwikdev/astro [destination] [adapter] [...options]Customize the command with the following arguments:
| Name | Type | Default value | Description |
|---|---|---|---|
| destination | String | ./qwik-astro-app | Directory of the project. |
| adapter | "deno" or "node" or "none" | none | Server adapter. |
Enhance your project setup with these additional flags:
| Name | Shortcut | Description |
|---|---|---|
--help | -h | Display all available options. |
--template | -t | Use an Astro template. |
--add / --no-add | -a / --no-a | Add QwikDev/astro to an existing project. |
--force / --no-force | -f / --no-f | Overwrite target directory, if needed. |
--copy / --no-copy | -c / --no-c | Copy files without overwriting. |
--biome / --no-biome | Use Biome instead of ESLint/Prettier. | |
The easiest way to explore QwikDev/Astro on your machine is by running the following command:
npm create @qwikdev/astro@latestStart Without Any Template
You can create a project with no template to keep it minimal or customize it from scratch. This approach uses only the default starter kit provided by the integration:
npm create @qwikdev/astro@latest my-projectTo skip all prompts and initialize without a template automatically:
npm create @qwikdev/astro@latest my-project --yesAdd Qwik/Astro to an Existing Project**
If you already have an existing project
and want to integrate QwikDev/Astro without creating a new project,
you can use the --add option:
npm create @qwikdev/astro@latest my-existing-project --addUse an Official Template
You can initialize a project with a pre-built template (e.g., minimal, portfolio, starlight, blog, etc.):
npm create @qwikdev/astro@latestFor developers looking to programmatically access the CLI functionality:
Basic Usage
Run the CLI programmatically without arguments:
import createQwikAstro from '@qwikdev/create-astro';
createQwikAstro();With Custom Arguments
Specify arguments directly:
import { run } from '@qwikdev/create-astro';
run(["./qwik-astro-app", "node"]);Definition Types
Define the structure of the CLI options and arguments:
export type Definition = {
destination: string;
adapter?: "deno" | "node"
aslemammad
zorofight94@gmail.com
--install / --no-install |
-i / --no-i |
| Automatically install dependencies. |
--git / --no-git | Use Git to save changes. |
--ci / --no-ci | Add CI workflow. |
--yes | -y | Accept all default configurations. |
--no | -n | Decline all default configurations. |
--dry-run | Simulate the setup process without executing. |
The full list of templates is quite long, so make sure to check it out to find one that fits your project needs.
Clone a Specific GitHub Repository
You can use any GitHub repository as a template:
npm create @qwikdev/astro@latest --template <user>/<repo>For a broader range of community-provided templates, visit the Awesome Astro repository.
Use Nested GitHub Examples
Paths to examples nested inside a GitHub repository are also supported:
npm create @qwikdev/astro@latest --template <user>/<repo>/path/to/exampleAdvanced Use Cases
You can combine multiple flags to set up your project exactly as needed:
npm create @qwikdev/astro my-existing-project --add --copy --template portfolio --yes --no-git --no-ciDefault Settings
Here are the default configurations:
export const defaultDefinition = {
destination: "./qwik-astro-app",
adapter: "none",
template: "",
add: undefined,
force: undefined,
copy: undefined,
biome: undefined,
install: undefined,
git: undefined,
ci: undefined,
yes: undefined,
no: undefined,
dryRun: undefined
} as const;Estimated unpacked size across 32 packages.
1.9 MB
Includes dependencies.
^0.11.0
1.9.0