@evjs/create-app 0.0.30 → 0.0.32

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -22,12 +22,15 @@ npx @evjs/create-app [name] [options]
22
22
 
23
23
  | Name | Description |
24
24
  |------|-------------|
25
- | **`basic-csr`** | Client-side only (React + TanStack Router). |
26
- | **`basic-mpa`** | Multi-page application with shared HTML template. |
27
- | **`basic-server-fns`** | Basic full-stack with server functions. |
28
- | **`configured-server-fns`** | Full-stack with `@evjs/create-app` + `ev.config.ts`. |
25
+ | **`basic`** | Basic full-stack example with routing and server functions. |
26
+ | **`mpa`** | Multi-page application with separate page entries. |
27
+ | **`api-routes`** | Programmatic REST API routes via `createRoute()`. |
29
28
  | **`complex-routing`** | Nested layouts, loaders, and search params. |
29
+ | **`custom-ws-transport`** | Custom transport example using WebSockets. |
30
+ | **`plugin-authoring`** | Starter focused on plugin authoring and bundler hooks. |
31
+ | **`with-sqlite`** | Full-stack CRUD example backed by SQLite. |
30
32
  | **`with-tailwind`** | Ready-to-go Tailwind CSS integration. |
33
+ | **`with-trpc`** | Example interoperating with tRPC. |
31
34
 
32
35
  ## Quick Start via npx
33
36
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@evjs/create-app",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "description": "Scaffold a new evjs project",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -1,11 +1,11 @@
1
- # basic-server-routes
1
+ # api-routes
2
2
 
3
3
  Programmatic REST route handlers using `createRoute()`.
4
4
 
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-basic-server-routes
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-api-routes",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -10,4 +10,4 @@ const app = createApp({
10
10
  routes: [healthHandler, postsHandler, postHandler],
11
11
  });
12
12
 
13
- export default app.fetch;
13
+ export default { fetch: app.fetch };
@@ -5,7 +5,7 @@ The standard starting point for an evjs application. Demonstrates both client-si
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-basic
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -23,5 +23,5 @@ npm run dev -w example-basic
23
23
  - Client-side routing with `createApp` and `createRoute`
24
24
  - `"use server"` directive for auto-discovered server functions
25
25
  - `useQuery(getUsers)` for type-safe data fetching
26
- - `useMutation({ mutationFn: createUser })` for mutations
26
+ - `useMutation({ mutationFn: createUser })` for server-side mutations
27
27
  - `getFnQueryKey(getUsers)` for cache invalidation
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-basic",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -5,7 +5,7 @@ Advanced routing patterns with TanStack Router.
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-complex-routing
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-complex-routing",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,11 +1,11 @@
1
- # websocket-fns
1
+ # custom-ws-transport
2
2
 
3
3
  Custom WebSocket transport for server function calls.
4
4
 
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-websocket-fns
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-custom-ws-transport",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,17 +1,17 @@
1
- # basic-mpa
1
+ # mpa
2
2
 
3
3
  Minimal multi-page application example using evjs `pages` config.
4
4
 
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-basic-mpa
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Build
12
12
 
13
13
  ```bash
14
- npm run build -w example-basic-mpa
14
+ npm run build
15
15
  ```
16
16
 
17
17
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-mpa",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,8 +1,8 @@
1
- # basic-plugins
1
+ # plugin-authoring
2
2
 
3
3
  Demonstrates the evjs plugin system with all available hooks:
4
4
 
5
- - **`bundler`** — modify the underlying bundler config (type-safe via `utoopack()` helper)
5
+ - **`bundlerConfig`** — modify the underlying bundler config (type-safe via `utoopack()` helper)
6
6
  - **`buildStart`** — run logic before compilation begins
7
7
  - **`buildEnd`** — run logic after compilation completes
8
8
  - **`transformHtml`** — modify the parsed HTML document after asset injection
@@ -17,4 +17,4 @@ npm run dev
17
17
 
18
18
  1. Console output from `buildStart` and `buildEnd` hooks during build
19
19
  2. The `<!-- Built with evjs | N asset(s) -->` comment in the output HTML (injected by `transformHtml`)
20
- 3. `.txt` file support added via the `bundler` hook (utoopack raw rule)
20
+ 3. `.txt` file support added via the `bundlerConfig` hook (utoopack raw rule)
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-plugin-authoring",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,11 +1,11 @@
1
- # sqlite-server-fns
1
+ # with-sqlite
2
2
 
3
3
  Full CRUD application with SQLite (node:sqlite) — users and todos.
4
4
 
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-sqlite-server-fns
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-with-sqlite",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-with-tailwind",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",
@@ -1,11 +1,11 @@
1
- # trpc-server-fns
1
+ # with-trpc
2
2
 
3
3
  tRPC interop alongside evjs server functions.
4
4
 
5
5
  ## Run
6
6
 
7
7
  ```bash
8
- npm run dev -w example-trpc-server-fns
8
+ npm run dev
9
9
  ```
10
10
 
11
11
  ## Key Files
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "example-with-trpc",
3
- "version": "0.0.30",
3
+ "version": "0.0.32",
4
4
  "private": true,
5
5
  "scripts": {
6
6
  "dev": "npx ev dev",