artos
Artos is a library I built mostly for myself to set up a simple API and and SPA, avoiding verbose code and focus on the actual application.
Last updated 5 months ago by hannesdahlberg .
ISC · Original npm · Tarball · package.json
$ cnpm install artos 
SYNC missed versions from official npm registry.

Artos

Artos is a library I built mostly for myself to set up a simple API and and SPA, avoiding verbose code and focus on the actual application.

Artos offers:

  • ORM
  • Server solution using express
  • Dependency injection and factory
  • Database migration
  • Scaffolding projects
  • Limited CLI command palette
  • Simple authentication service

The library is documented at most and offered as is. No guaranties that it will work out of the box. My goal is to offer a stable solution but for my needs this is working very well for now.

Get Started

Download the scaffold folder from the repo and put the content in the root folder of your project. Install by running either npm or yarn. All dependencies are in the package.json folder.

The scaffold project has two major folders: api and spa. Each one is it's own application and in theory can be run on their own. Instead however they are run together under one express instance. Look at the /server.ts file to see for your self. The root of each application has and index.ts file (/api/index.ts). Here you will find configs for that server.

API apps has the following file structure:

  • index.ts - The server configs
  • routes.ts - Routing
  • middlewares.ts - Route guards
  • controllers/ - Controllers
  • models/ - ORM models

Using yarn you can run the artoo CLI. Available commands are:

  • yarn artoo migrate - Run migration scripts from your storage/migrations folder
  • yarn artoo create:migration --class="NAME" - Create a new migration script named after the class argument
  • yarn artoo create:user --username="user@email.com" --password="yourpasswordhere" --group="nameofgroup" - Creating a new user and insert it to the database. If group doesn't exists it will be created.

Feel happy to ask questions and submit pull requests. This document will be updated as the project continues.

Current Tags

  • 3.0.1                                ...           latest (5 months ago)

21 Versions

  • 3.0.1                                ...           5 months ago
  • 3.0.0                                ...           5 months ago
  • 2.2.0                                ...           6 months ago
  • 2.1.2                                ...           6 months ago
  • 2.1.1                                ...           6 months ago
  • 2.1.0                                ...           6 months ago
  • 2.0.1                                ...           6 months ago
  • 2.0.0                                ...           7 months ago
  • 1.4.2                                ...           7 months ago
  • 1.4.1                                ...           7 months ago
  • 1.4.0                                ...           7 months ago
  • 1.3.0                                ...           7 months ago
  • 1.2.0                                ...           7 months ago
  • 1.1.5                                ...           7 months ago
  • 1.1.4                                ...           7 months ago
  • 1.1.3                                ...           7 months ago
  • 1.1.2                                ...           7 months ago
  • 1.1.1                                ...           7 months ago
  • 1.1.0                                ...           7 months ago
  • 1.0.0                                ...           7 months ago
  • 0.0.1                                ...           7 months ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 43
Dependencies (37)
Dev Dependencies (0)
None
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |