Code Monkey home page Code Monkey logo

ctr's Introduction

Cybertown Revival

This project is an attempt to resurrect and preserve Cybertown, a VRML based community from the mid-90s/early-00s. This repository contains the entire codebase for the new platform, built by the community.

How to Contribute

As a Developer

We always welcome others to help out with VRML and the Single Page Application (SPA) and API. Take a look at our issue, fork this repository and start contributing. When you are ready, create a pull request, and we will review your changes to be merged into the official master branch.

As a User

Submitting bugs, feedback and commenting on issues is the best way for non-developers to help with the project.

Dev Stack

  • Node.js
  • Vue.js
  • Tailwind.css
  • MySQL
  • Nginx
  • socket.io
  • docker
  • VRML

Development Environment Setup Instructions

We utilise docker to manage the entire development environment and to make it easy to set up and run.

Requirements

You will need to have the following already installed on your machine and a basic understanding in order to run the development environment:

You may also wish to install Docker for Desktop if you wish. For beginners, there are plenty of tutorials and videos online on installation and the basics of node, npm and docker.

Initial Setup

  1. Clone this repository to your machine.
  2. Rename spa/.env.example to spa/.env and api/.env.example to api/.env.
  3. In the cloned directory, run docker-compose up from command line. This will install the docker environment, install node dependencies via npm and start the servers.
  4. Navigate to the spa/ directory and run npm run dev to compile the SPA.
  5. In your browser, visit http://localhost:8001/ to confirm it's running.

To run the environment again in the future, simple repeat steps 2 onwards.

Creating the database

To initialize a database within the mysql container, run the command below from within the api/ directory.

Running this will create a new database using settings configured in api/knexfile.ts:

npm run db:init

After the database is created, the schema and some necessary seed data are created automatically.

Automatically Compiling the SPA

When making changes to the SPA, provided you have ran npm run dev from spa/ all your changes will be automatically re-compiled.

Coding Standards

  • 2 space indentation
  • 100-110 max line length
  • wrapped lines can have +1 space indentation
  • use single quotes for strings, excluding SQL queries.
  • use triple equals (===) for comparisons
  • no trailing spaces
  • always leave a trailing (,) comma in lists
  • blank line at the end of files

ctr's People

Contributors

salleematthew avatar dburleson avatar smile0711 avatar themikesanto avatar xdkrgl avatar sgeo avatar theyapps avatar

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.