Giter Club home page Giter Club logo

monorepo's Introduction

@kampus/monorepo

kamp.us web projects & packages

IMPORTANT NOTE

This repository is under heavy development, if you want to contribute either go through package.json file of each workspace and start familiarizing yourself with the technologies we are using or join our discord server and say hi to us at #kampus-projects channel.

Getting started

1. Cloning the project

  • Fork kamp-us/monorepo under your personal account.
    • eg: usirin/monorepo
  • Clone the project to your local computer:
# Download Repository
git clone [email protected]:kamp-us/monorepo.git
# Move into repository
cd monorepo
  • Install dependencies.
npm ci

2. Modifying hosts file

127.0.0.1 localhost.kamp.us
127.0.0.1 pano.localhost.kamp.us
127.0.0.1 sozluk.localhost.kamp.us
127.0.0.1 gql.localhost.kamp.us

3. Setting up .env files

  • Duplicate .env.example files and rename them as .env in the following folders: db/prisma, apps/gql, apps/kampus.

4. Prisma Setup and Database Configuration

  • Move to db/prisma folder.
cd db/prisma
  • Start the image. (You should have docker installed.)
docker-compose up -d
  • Generate artifacts. (e.g. Prisma Client)
npm run prisma:generate
  • Push the Prisma schema state to the database.
npm run prisma:push
  • Run seed command to fill database with demo data.
npm run prisma:seed

5. Running dev servers

  • Run the command below at the root folder.
# Runs "gql" and "kampus" apps so the platform can be alive with 1 command.
npm run web
  • Now you can go to localhost.kamp.us:3000 to see it live. ๐Ÿš€
# Runs all "dev" commands on each package inside the workspace
npm run dev
# Runs only "gql" server so backend work can be done separately.
npm run gql

Structure

  • /apps: services & apps
  • /db: packages that is relevant to database
  • /config: packages that is relevant to configuration
  • /packages: internal (and maybe external in the future) npm packages

These folders are registered as workspaces in package.json

Use Correct Node Version

If you haven't already install Volta, you can install install it with:

curl https://get.volta.sh | bash

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.