-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from sergio222-dev/develop
added more filter options
- Loading branch information
Showing
11 changed files
with
330 additions
and
137 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,78 +1,6 @@ | ||
# Qwik City App ⚡️ | ||
|
||
<img height="200" src="https://github.com/SAWARATSUKI/ServiceLogos/blob/main/Qwik.js/Qwik.png?raw=true" width="400"/> | ||
<img height="200" src="https://github.com/SAWARATSUKI/ServiceLogos/blob/main/TypeScript/TypeScript.png?raw=true" width="400"/> | ||
|
||
- [Qwik Docs](https://qwik.dev/) | ||
- [Discord](https://qwik.dev/chat) | ||
- [Qwik GitHub](https://github.com/BuilderIO/qwik) | ||
- [@QwikDev](https://twitter.com/QwikDev) | ||
- [Vite](https://vitejs.dev/) | ||
|
||
--- | ||
|
||
## Project Structure | ||
|
||
This project is using Qwik with [QwikCity](https://qwik.dev/qwikcity/overview/). QwikCity is just an extra set of tools on top of Qwik to make it easier to build a full site, including directory-based routing, layouts, and more. | ||
|
||
Inside your project, you'll see the following directory structure: | ||
|
||
``` | ||
├── public/ | ||
│ └── ... | ||
└── src/ | ||
├── components/ | ||
│ └── ... | ||
└── routes/ | ||
└── ... | ||
``` | ||
|
||
- `src/routes`: Provides the directory-based routing, which can include a hierarchy of `layout.tsx` layout files, and an `index.tsx` file as the page. Additionally, `index.ts` files are endpoints. Please see the [routing docs](https://qwik.dev/qwikcity/routing/overview/) for more info. | ||
|
||
- `src/components`: Recommended directory for components. | ||
|
||
- `public`: Any static assets, like images, can be placed in the public directory. Please see the [Vite public directory](https://vitejs.dev/guide/assets.html#the-public-directory) for more info. | ||
|
||
## Add Integrations and deployment | ||
|
||
Use the `pnpm qwik add` command to add additional integrations. Some examples of integrations includes: Cloudflare, Netlify or Express Server, and the [Static Site Generator (SSG)](https://qwik.dev/qwikcity/guides/static-site-generation/). | ||
|
||
```shell | ||
pnpm qwik add # or `pnpm qwik add` | ||
``` | ||
|
||
## Development | ||
|
||
Development mode uses [Vite's development server](https://vitejs.dev/). The `dev` command will server-side render (SSR) the output during development. | ||
|
||
```shell | ||
npm start # or `pnpm start` | ||
``` | ||
|
||
> Note: during dev mode, Vite may request a significant number of `.js` files. This does not represent a Qwik production build. | ||
## Preview | ||
|
||
The preview command will create a production build of the client modules, a production build of `src/entry.preview.tsx`, and run a local server. The preview server is only for convenience to preview a production build locally and should not be used as a production server. | ||
|
||
```shell | ||
pnpm preview # or `pnpm preview` | ||
``` | ||
|
||
## Production | ||
|
||
The production build will generate client and server modules by running both client and server build commands. The build command will use Typescript to run a type check on the source code. | ||
# LDB | ||
|
||
Generate types for database | ||
```shell | ||
pnpm build # or `pnpm build` | ||
supabase gen types typescript --local > ./database.types.ts | ||
``` | ||
|
||
## Fastify Server | ||
|
||
This app has a minimal [Fastify server](https://fastify.dev/) implementation. After running a full build, you can preview the build using the command: | ||
|
||
``` | ||
pnpm serve | ||
``` | ||
|
||
Then visit [http://localhost:3000/](http://localhost:3000/) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { component$, Slot, useSignal } from "@builder.io/qwik"; | ||
|
||
interface AccordionProps { | ||
title: string; | ||
} | ||
|
||
export const Accordion = component$<AccordionProps>(({ title }) => { | ||
|
||
const isOpen = useSignal(false) | ||
|
||
return ( | ||
<div class="rounded"> | ||
<hr /> | ||
<div class="flex items-center cursor-pointer hover:bg-primary hover:text-white hover:fill-white px-2 py-4" onClick$={() => isOpen.value = !isOpen.value}> | ||
<p class="text-lg font-bold flex-1">{title}</p> | ||
</div> | ||
<div hidden={!isOpen.value} class="px-2"> | ||
<Slot/> | ||
</div> | ||
<hr /> | ||
</div> | ||
) | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.