-
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 #1 from daawaan4U/feat/frontend-crud
Feat/frontend crud
- Loading branch information
Showing
69 changed files
with
3,687 additions
and
1,215 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,42 +1,49 @@ | ||
# pathfinding | ||
# 🗺️ pathfinding | ||
|
||
🗺️ visualize pathfinding on custom mazes | made with sveltekit 💼 | ||
A **CRUD** application made with _SvelteKit_ for visualizing the \*A\*\* algorithm on customizable mazes. Originally made for our CS116 Project. | ||
|
||
# create-svelte | ||
## Setup | ||
|
||
Everything you need to build a Svelte project, powered by [`create-svelte`](https://github.com/sveltejs/kit/tree/main/packages/create-svelte). | ||
### Installation | ||
|
||
## Creating a project | ||
Install the latest _NodeJS_ LTS version from the [official website](https://nodejs.org/en) or through Node Version Manager: [`nvm` for Linux](https://github.com/nvm-sh/nvm), and [`nvm-win` for Windows](https://github.com/coreybutler/nvm-windows). | ||
|
||
If you're seeing this, you've probably already done this step. Congrats! | ||
Afterwards, install dependencies (preferably `pnpm`) with the following commands: | ||
|
||
```bash | ||
# create a new project in the current directory | ||
npm create svelte@latest | ||
|
||
# create a new project in my-app | ||
npm create svelte@latest my-app | ||
``` | ||
npm install -g pnpm | ||
pnpm install | ||
``` | ||
|
||
## Developing | ||
### Docker (for development) | ||
|
||
Once you've created a project and installed dependencies with `npm install` (or `pnpm install` or `yarn`), start a development server: | ||
_Docker Compose_ is used to run necessary third-party services such as _PostgreSQL_ for development. Install _Docker Desktop_ from the [offical website](https://docs.docker.com/desktop/) to start. | ||
|
||
```bash | ||
npm run dev | ||
# start containers | ||
docker-compose up -d | ||
|
||
# or start the server and open the app in a new browser tab | ||
npm run dev -- --open | ||
# stop containers | ||
docker-compose stop | ||
|
||
# delete containers (--volumes is optional if you also want to remove data volumes) | ||
docker-compose down --volumes | ||
``` | ||
|
||
## Building | ||
## Development | ||
|
||
To create a production version of your app: | ||
### Database Migration | ||
|
||
```bash | ||
npm run build | ||
The project lacks a Database Migration Framework for automatically syncing schemas. In order to setup the database schema for this project, a simple script can be used instead whicn can be executed with the following command. | ||
|
||
``` | ||
pnpm vite-node "./src/lib/server/migrations/migrate" | ||
``` | ||
|
||
You can preview the production build with `npm run preview`. | ||
### Development Server | ||
|
||
Start the development server with the following command. | ||
|
||
> To deploy your app, you may need to install an [adapter](https://kit.svelte.dev/docs/adapters) for your target environment. | ||
``` | ||
pnpm run dev | ||
``` |
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.