Skip to content
Merged
Prev Previous commit
Next Next commit
🌏
  • Loading branch information
manucorporat committed Jul 5, 2023
commit f444a3b087e5eee4889589df3dcdf61493972320
2 changes: 1 addition & 1 deletion packages/create-vite/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ import {
blue,
cyan,
green,
lightBlue,
lightGreen,
lightRed,
magenta,
red,
reset,
yellow,
lightBlue
} from 'kolorist'

// Avoids autoconversion to number of the project name by defining that the args
Expand Down
10 changes: 5 additions & 5 deletions packages/create-vite/template-qwik-ts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ This starter is using a pure CSR (Client Side Rendering) mode. This means, that

```ts
export default defineConfig({
plugins: [qwikVite({
csr: true,
})],
plugins: [
qwikVite({
csr: true,
}),
],
})
```

Expand All @@ -22,8 +24,6 @@ $ npm install # or pnpm install or yarn install

Learn more on the [Qwik Website](https://qwik.builder.io) and join our community on our [Discord](https://qwik.builder.io/chat)



## Available Scripts

In the project directory, you can run:
Expand Down
22 changes: 16 additions & 6 deletions packages/create-vite/template-qwik-ts/src/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,27 @@ export const App = component$(() => {
<>
<div>
<a href="https://vitejs.dev" target="_blank">
<img src={viteLogo} width={32} height={32} class="logo" alt="Vite logo" />
<img
src={viteLogo}
width={32}
height={32}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Vite logo has the same size as the framework logo in other templates. See
image

Same for the JS template

class="logo"
alt="Vite logo"
/>
</a>
<a href="https://qwik.builder.io" target="_blank">
<img src={qwikLogo} width={110} height={118} class="logo qwik" alt="Qwik logo" />
<img
src={qwikLogo}
width={110}
height={118}
class="logo qwik"
alt="Qwik logo"
/>
</a>
</div>
<h1>Vite + Qwik</h1>
<div class="card">
<button onClick$={() => count.value++}>
count is {count.value}
</button>
<button onClick$={() => count.value++}>count is {count.value}</button>
<p>
Edit <code>src/app.tsx</code> and save to test HMR
</p>
Expand All @@ -31,4 +41,4 @@ export const App = component$(() => {
</p>
</>
)
});
})
10 changes: 6 additions & 4 deletions packages/create-vite/template-qwik-ts/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import { defineConfig } from 'vite'
import { qwikVite } from '@builder.io/qwik/optimizer';
import { qwikVite } from '@builder.io/qwik/optimizer'

// https://vitejs.dev/config/
export default defineConfig({
plugins: [qwikVite({
csr: true,
})],
plugins: [
qwikVite({
csr: true,
}),
],
})
10 changes: 5 additions & 5 deletions packages/create-vite/template-qwik/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,11 @@ This starter is using a pure CSR (Client Side Rendering) mode. This means, that

```ts
export default defineConfig({
plugins: [qwikVite({
csr: true,
})],
plugins: [
qwikVite({
csr: true,
}),
],
})
```

Expand All @@ -22,8 +24,6 @@ $ npm install # or pnpm install or yarn install

Learn more on the [Qwik Website](https://qwik.builder.io) and join our community on our [Discord](https://qwik.builder.io/chat)



## Available Scripts

In the project directory, you can run:
Expand Down
22 changes: 16 additions & 6 deletions packages/create-vite/template-qwik/src/app.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,27 @@ export const App = component$(() => {
<>
<div>
<a href="https://vitejs.dev" target="_blank">
<img src={viteLogo} width={32} height={32} class="logo" alt="Vite logo" />
<img
src={viteLogo}
width={32}
height={32}
class="logo"
alt="Vite logo"
/>
</a>
<a href="https://qwik.builder.io" target="_blank">
<img src={qwikLogo} width={110} height={118} class="logo qwik" alt="Qwik logo" />
<img
src={qwikLogo}
width={110}
height={118}
class="logo qwik"
alt="Qwik logo"
/>
</a>
</div>
<h1>Vite + Qwik</h1>
<div class="card">
<button onClick$={() => count.value++}>
count is {count.value}
</button>
<button onClick$={() => count.value++}>count is {count.value}</button>
<p>
Edit <code>src/app.tsx</code> and save to test HMR
</p>
Expand All @@ -31,4 +41,4 @@ export const App = component$(() => {
</p>
</>
)
});
})
10 changes: 6 additions & 4 deletions packages/create-vite/template-qwik/vite.config.js
Original file line number Diff line number Diff line change
@@ -1,9 +1,11 @@
import { defineConfig } from 'vite'
import { qwikVite } from '@builder.io/qwik/optimizer';
import { qwikVite } from '@builder.io/qwik/optimizer'

// https://vitejs.dev/config/
export default defineConfig({
plugins: [qwikVite({
csr: true,
})],
plugins: [
qwikVite({
csr: true,
}),
],
})