Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion frontend/.cta.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@
"t3env",
"tanstack-query"
]
}
}
21 changes: 5 additions & 16 deletions frontend/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@ If you prefer not to use Tailwind CSS:

## Linting & Formatting


This project uses [eslint](https://eslint.org/) and [prettier](https://prettier.io/) for linting and formatting. Eslint is configured using [tanstack/eslint-config](https://tanstack.com/config/latest/docs/eslint). The following scripts are available:

```bash
Expand All @@ -41,7 +40,6 @@ bun --bun run format
bun --bun run check
```


## Deploy with Nitro

This project uses Nitro as a generic server adapter, so it can run on any Node-compatible host.
Expand All @@ -55,7 +53,6 @@ The build output is a self-contained Node server. To deploy, push the `dist/` di

For host-specific presets (Vercel, Netlify, Cloudflare, AWS Lambda, etc.) and tuning, see https://v3.nitro.build/deploy.


## Shadcn

Add components using the latest version of [Shadcn](https://ui.shadcn.com/).
Expand All @@ -64,7 +61,6 @@ Add components using the latest version of [Shadcn](https://ui.shadcn.com/).
pnpm dlx shadcn@latest add button
```


## T3Env

- You can use T3Env to add type safety to your environment variables.
Expand All @@ -74,16 +70,11 @@ pnpm dlx shadcn@latest add button
### Usage

```ts
import { env } from "#/env";
import { env } from '#/env'

console.log(env.VITE_APP_TITLE);
console.log(env.VITE_APP_TITLE)
```






## Routing

This project uses [TanStack Router](https://tanstack.com/router) with file-based routing. Routes are managed as files in `src/routes`.
Expand All @@ -101,7 +92,7 @@ Now that you have two routes you can use a `Link` component to navigate between
To use SPA (Single Page Application) navigation you will need to import the `Link` component from `@tanstack/react-router`.

```tsx
import { Link } from "@tanstack/react-router";
import { Link } from '@tanstack/react-router'
```

Then anywhere in your JSX you can use it like so:
Expand Down Expand Up @@ -169,11 +160,11 @@ const getServerTime = createServerFn({
// Use in a component
function MyComponent() {
const [time, setTime] = useState('')

useEffect(() => {
getServerTime().then(setTime)
}, [])

return <div>Server time: {time}</div>
}
```
Expand Down Expand Up @@ -226,8 +217,6 @@ function PeopleComponent() {

Loaders simplify your data fetching logic dramatically. Check out more information in the [Loader documentation](https://tanstack.com/router/latest/docs/framework/react/guide/data-loading#loader-parameters).



# Learn More

You can learn more about all of the offerings from TanStack in the [TanStack documentation](https://tanstack.com).
Expand Down
3 changes: 3 additions & 0 deletions frontend/bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion frontend/components.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@
"hooks": "#/hooks"
},
"iconLibrary": "lucide"
}
}
2 changes: 1 addition & 1 deletion frontend/eslint.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,6 @@ export default [
},
},
{
ignores: ['eslint.config.js', 'prettier.config.js'],
ignores: ['eslint.config.js', 'prettier.config.js', '.output/**'],
},
]
3 changes: 2 additions & 1 deletion frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
"check": "prettier --check ."
},
"dependencies": {
"@microsoft/fetch-event-source": "^2.0.1",
"@t3-oss/env-core": "^0.13.10",
"@tailwindcss/vite": "^4.1.18",
"@tanstack/react-devtools": "latest",
Expand Down Expand Up @@ -62,4 +63,4 @@
"lightningcss"
]
}
}
}
6 changes: 3 additions & 3 deletions frontend/prettier.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
const config = {
semi: false,
singleQuote: true,
trailingComma: "all",
};
trailingComma: 'all',
}

export default config;
export default config
Loading