Skip to content

Commit

Permalink
refactor: simplify CLI starters (#6632)
Browse files Browse the repository at this point in the history
  • Loading branch information
thejackshelton authored Jul 3, 2024
1 parent 8a5ef13 commit 220536f
Show file tree
Hide file tree
Showing 64 changed files with 10 additions and 774 deletions.
5 changes: 4 additions & 1 deletion packages/create-qwik/src/run-create-interactive-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,10 @@ export async function runCreateInteractiveCli(): Promise<CreateAppResult> {
throw new Error('Base app not found');
}

const starterApps = templateManager.templates.filter((a) => a.id !== baseApp.id);
// sorted alphabetically
const starterApps = templateManager.templates
.filter((a) => a.id !== baseApp.id)
.sort((a, b) => a.name.localeCompare(b.name));

const outDir: string = resolveRelativeDir(projectNameAnswer.trim());
baseApp.target = outDir;
Expand Down
3 changes: 1 addition & 2 deletions scripts/validate-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,8 @@ async function validateCreateQwikCli() {
const tmpDir = join(__dirname, '..', 'dist-dev');

await Promise.all([
validateStarter(api, tmpDir, 'basic', true, `👻`),
validateStarter(api, tmpDir, 'playground', true, `👻`),
validateStarter(api, tmpDir, 'empty', true, `🫙`),
validateStarter(api, tmpDir, 'site-with-visual-cms', true, `😈`),
validateStarter(api, tmpDir, 'library', false, `📚`),
]).catch((e) => {
console.error(e);
Expand Down
2 changes: 1 addition & 1 deletion starters/apps/empty/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "qwik-empty-starter",
"description": "App with Routing built-in ready to create your app",
"description": "Blank project with routing included",
"type": "module",
"__qwik__": {
"priority": 1,
Expand Down
4 changes: 2 additions & 2 deletions starters/apps/library/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "qwik-library-name",
"description": "Create a reusable Qwik component library",
"description": "Create a Qwik library",
"version": "0.0.1",
"private": false,
"main": "./lib/index.qwik.mjs",
Expand Down Expand Up @@ -48,7 +48,7 @@
"vite-tsconfig-paths": "^4.2.1"
},
"__qwik__": {
"displayName": "Component library (Qwik)",
"displayName": "Library (Qwik)",
"priority": -1,
"docs": [
"https://qwik.dev/docs/getting-started/"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "qwik-basic-starter",
"description": "Demo App with Routing built-in (recommended)",
"description": "Demo app with sample routes",
"type": "module",
"__qwik__": {
"priority": 2,
"displayName": "Basic App (Qwik City + Qwik)",
"displayName": "Playground App (Qwik City + Qwik)",
"qwikCity": true,
"docs": [
"https://qwik.dev/docs/getting-started/"
Expand Down
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 0 additions & 2 deletions starters/apps/site-with-visual-cms/.env

This file was deleted.

15 changes: 0 additions & 15 deletions starters/apps/site-with-visual-cms/README.md

This file was deleted.

17 changes: 0 additions & 17 deletions starters/apps/site-with-visual-cms/package.json

This file was deleted.

1 change: 0 additions & 1 deletion starters/apps/site-with-visual-cms/public/favicon.svg

This file was deleted.

9 changes: 0 additions & 9 deletions starters/apps/site-with-visual-cms/public/manifest.json

This file was deleted.

Empty file.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

36 changes: 0 additions & 36 deletions starters/apps/site-with-visual-cms/src/components/gauge/index.tsx

This file was deleted.

This file was deleted.

Loading

0 comments on commit 220536f

Please sign in to comment.