diff --git a/packages/qwik/src/cli/utils/templates.ts b/packages/qwik/src/cli/utils/templates.ts index 1acfbfc0c0a..2ed41a62565 100644 --- a/packages/qwik/src/cli/utils/templates.ts +++ b/packages/qwik/src/cli/utils/templates.ts @@ -1,5 +1,5 @@ import fs from 'node:fs'; -import { join } from 'node:path'; +import { join, sep } from 'node:path'; import type { TemplateSet } from '../types'; import { getFilesDeep } from './utils'; @@ -58,7 +58,7 @@ export async function readTemplates(rootDir: string) { } function parseTemplatePath(path: string, type: string) { - const parts = path.split(`/${type}/`); + const parts = path.split(sep + type + sep); return { absolute: path,