Standard Solid
Search…
⌃K

Standard Solid App Framework

Standard Solid is a web-application framework for building highly configurable & decentralized apps using Node.js, Solid, and SKL. It was was created with the goal of making it incredibly easy for developers to build Solid applications. Taking inspiration from the success of Ruby on Rails and Lad, it comes pre-configured with everything needed to create an application that can:
  • Store application data in a database (relational or key-value)
  • Expose an API (REST, GraphQL, etc.)
  • Run asyncronous workloads in the background
  • (Coming Soon) Store user data in a Solid pod
  • (Coming Soon) Authenticate users with Solid OIDC

Features

Dependency Injection

The Standard Solid framework is designed to be flexible such that people can easily run different configurations. To do so, Standard Solid uses the dependency injection framework Components.js.
Components.js allows components to be instantiated and wired together declaratively using semantic configuration files. Standard Solid also uses Components-Generator.js to automatically generate the necessary description configurations of all classes. Components are configured in JSON files, which makes it so that changing the configuration does not require any changes to the code.

Storage

Solid on Rails utilizes the Data Mapper Pattern to separate an application's domain logic and it's usage of databases to store data. This means that you can create applications that are loosely coupled, and thus hightly scalable and maintainable.
The Data Mapper Pattern is implemented using TypeORM.

Routes

Like in Rails, routes to connect URLs to code for the application's API or web pages are defined in a configuration file. Each route matches a URL pattern and HTTP method to a specific handler (or a chain of handlers). These handlers are defined in JSON using the dependency injection framework Components.js.

Background Jobs

Solid on Rails comes with a built in system for scheduling background jobs to be executed outside of the main process. Background job queues can solve many different problems, from smoothing out processing peaks to creating robust communication channels between microservices or offloading heavy work from one server to many smaller workers, etc.
A variety of queuing backends can be used but the default configuration uses Bull.

Requirements

Please ensure your operating system has the following software installed:
If your application doesn't need background job processing, you don't need to run Redis (See How to remove Background Jobs).
If your application doesn't need to store applicaton data, you don't need to run a database (See How to remove Application Data Storage).

Quick Start

Create a Node.js application (if you haven't already):
mkdir my-application
cd my-application
npm init
Install the latest server version from the npm package repository:
npm install --save @comake/solid-on-rails
Add the start command to scripts in your package.json
"scripts": {
"start": "npx solid-on-rails"
}
Start the server! 🚀
npm run start
Continue to the Getting Started guide below to learn how to create your own Components.js configuration to customize your application with your own routes, plugins, background jobs, and more.
Last modified 1mo ago