Skip to content

Deno and Svelte marketplace application, that allow users to view, filter, and create new advertisements.

License

Notifications You must be signed in to change notification settings

BartekStolarek/Adverter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Adverter

Description

Deno and Svelte marketplace application, that allow users to view, filter, and create new advertisements.

How to set up the project

  1. Make sure you have Deno installed on your machine (for running backend), alongisde with Node&npm (for running frontend).
  2. To run backend app, open terminal, navigate to adverter/backend folder and run:
deno run --allow-net --allow-read --allow-write server.ts

Deno backend app should start working on localhost:5000 by default.

  1. To run frontend app, open terminal, navigate to adverter/frontend folder and run:
npm run dev

Svelte frontend app should start working on localhost:8080 by default. App is set to communicate with backend on localhost:5000 by default. Open localhost:8080 in your browser to check it out!

Screens

API

This Deno server operates on a JSON data located under ./data/adverts.json file instead of a classic database (for simplicity). It exposes the following endpoints:

  • GET /api/v1/advertisements - returns a JSON containing an array of advertisements stored in the JSON file.
  • POST /api/v1/advertisements - accepts a valid advertisement object in a body and responds with a JSON containing an array of updated advertisements.
  • DELETE /api/v1/advertisements - accepts a valid id object in a body, and responds with a JSON containing an array of updated advertisements.

About

Deno and Svelte marketplace application, that allow users to view, filter, and create new advertisements.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published