All Projects โ†’ floyd-framework โ†’ Cli

floyd-framework / Cli

Licence: mit
GraphQL back-end framework with first-class Typescript support

Programming Languages

typescript
32286 projects

Projects that are alternatives of or similar to Cli

Goyave
๐Ÿ Elegant Golang REST API Framework
Stars: โœญ 811 (+2091.89%)
Mutual labels:  api, framework, backend
Micro
Micro is a distributed cloud operating system
Stars: โœญ 10,778 (+29029.73%)
Mutual labels:  api, framework, backend
Autoserver
Create a full-featured REST/GraphQL API from a configuration file
Stars: โœญ 188 (+408.11%)
Mutual labels:  api, cli, framework
Opensourcetest
OpenSourceTest็”ฑ่‡ชๅŠจๅŒ–ๆต‹่ฏ•-ๅคœ่กŒ่€…็คพๅŒบ็ปดๆŠค๏ผŒๆไพ›็š„ๆ˜ฏๆ›ดๅคšๅœฐ็ตๆดปๆ€งๅ’Œๅฏ้…็ฝฎๆ€ง
Stars: โœญ 37 (+0%)
Mutual labels:  api, framework
Zato
ESB, SOA, REST, APIs and Cloud Integrations in Python
Stars: โœญ 889 (+2302.7%)
Mutual labels:  api, backend
Github Funding Yml Updater
Update multiple repositories's `.github/FUNDING.yml` via GitHub API
Stars: โœญ 17 (-54.05%)
Mutual labels:  api, cli
Deno Drash
A REST microframework for Deno's HTTP server with zero 3rd party dependencies.
Stars: โœญ 795 (+2048.65%)
Mutual labels:  api, framework
Currencyviewer
Short python framework that dynamically displays and converts the cryptocurrencies in your Kraken wallet into equivalents fiat money.
Stars: โœญ 13 (-64.86%)
Mutual labels:  api, framework
Get File
CLI and API to get a single file from Github repository.
Stars: โœญ 9 (-75.68%)
Mutual labels:  api, cli
Newsreap
Usenet Framework that supports posting, indexing and retrieving
Stars: โœญ 21 (-43.24%)
Mutual labels:  cli, framework
Whatsapp Framework
โš—๏ธWhatsapp python api
Stars: โœญ 945 (+2454.05%)
Mutual labels:  api, framework
Exiftool
ExifTool meta information reader/writer
Stars: โœญ 832 (+2148.65%)
Mutual labels:  api, cli
Api Platform
Create REST and GraphQL APIs, scaffold Jamstack webapps, stream changes in real-time.
Stars: โœญ 7,144 (+19208.11%)
Mutual labels:  api, framework
Aruba
Test command-line applications with Cucumber-Ruby, RSpec or Minitest. The most up to date documentation can be found on Cucumber.Pro (https://app.cucumber.pro/projects/aruba)
Stars: โœญ 900 (+2332.43%)
Mutual labels:  cli, framework
Horrible Downloader
horriblesubs.info python API and CLI
Stars: โœญ 28 (-24.32%)
Mutual labels:  api, cli
Fusio
Open source API management platform
Stars: โœญ 946 (+2456.76%)
Mutual labels:  api, backend
Falko Api
๐Ÿ“ˆ Falko API: Plataform for agile projects management ๐Ÿ“Š
Stars: โœญ 13 (-64.86%)
Mutual labels:  api, backend
Oas Generator
NodeJS RESTful APIs scaffolding based OpenAPI 3.x specs using oas-tools and express.
Stars: โœญ 32 (-13.51%)
Mutual labels:  api, cli
Graphql Framework Experiment
Code-First Type-Safe GraphQL Framework
Stars: โœญ 698 (+1786.49%)
Mutual labels:  api, framework
Swiftkit
Start your next Open-Source Swift Framework ๐Ÿ“ฆ
Stars: โœญ 785 (+2021.62%)
Mutual labels:  cli, framework

Floyd

Join the chat at https://gitter.im/floyd-framework/cli

The famework for building GraphQL backends, with first-class support for Typescript. You won't need to spend time trying to set up the GraphQL backend, Floyd will do it for you.

Why

REST APIs are cumbersome to build and even tougher to deal with (for frontend developers). GraphQL eliminates most of the problems developers face while building and using APIs. See more benefits of GraphQL here.

Concepts

Floyd only has a few concepts you need to understand to get up and running with it. It is made to be as simple as possible to pick up and use.

Components

A Floyd app is divided into multiple components, with each component having its own Schema, Resolvers and Model.

  • Schema: It is a GraphQL schema with its own queries, mutations and subscriptions. Learn more here
  • Resolvers: These are the functions you write in code that map to the queries, mutations and subscriptions you have defined. Lern more here
  • Model: This is your Database model for your component. It is the M in MVC. In this file, you specify your model's databse schema and export the model object.

Typescript

One of the advantages of GraphQL over REST is you can know beforehand exactly what the type and structure of the result will be. We wanted to extend this feature into all your app's code and hence we chose Typescript. Typescript helps you avoid a lot of the errors that might encounter during runtime in Javascript simply because you used the wrong type of object or didn't know what members the object has. Learn more here.

Getting started

Install the Floyd CLI

with npm:

npm install -g floyd-cli

Or using Yarn:

yarn global add floyd-cli

Create your project in any directory you want using the create command:

floyd create <name> <path>

For example:

floyd create hello-world ~/playground

will create your project in ~/playground/hello-world/

Learn more about the command here

Add a component to your project using the add command:

Make sure you are inside your project's directory, then to add a component named cat:

floyd add cat

It will create a folder cat in your components folder as shown in the project structure below.

Learn more about the command here

Project structure

Floyd has a simple and recognisable project structure so when you pick up someone else's Floyd app to maintain or contribute to, you feel right at home.

.
โ”œโ”€โ”€ app
โ”‚   โ”œโ”€โ”€ app.config.json
โ”‚   โ”œโ”€โ”€ components
โ”‚   โ”‚   โ””โ”€โ”€ cat
โ”‚   โ”‚       โ”œโ”€โ”€ model.ts
โ”‚   โ”‚       โ”œโ”€โ”€ resolvers.ts
โ”‚   โ”‚       โ””โ”€โ”€ schema.graphql
โ”‚   โ”œโ”€โ”€ db.ts
โ”‚   โ”œโ”€โ”€ helpers.ts
โ”‚   โ”œโ”€โ”€ index.ts
โ”‚   โ”œโ”€โ”€ resolvers.ts
โ”‚   โ””โ”€โ”€ schema.graphql
โ”œโ”€โ”€ LICENSE
โ”œโ”€โ”€ package.json
โ”œโ”€โ”€ package-lock.json
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ tsconfig.json

The app folder will contain all the code for your backend.

  • app.config.json will contain all your configuration options, like database URL, name of all the components, etc.
  • The components folder will contain all your components, each in its separate folder by name.
  • schema.graphql will contain the global types of your schema, i.e. types needed by more than one component's schema.
  • Similarly, resolvers.ts will contain all the global resolvers that you might need, just make sure none (neither global nor component specific) of your resolver names collide, since all of them will be made available in the same scope.

Contributing

For a guide on how to contribute to this project, click here.

Code of Conduct

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].