Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/amaui-org/amaui-models
Models
https://github.com/amaui-org/amaui-models
amaui back-end backend browser express front-end frontend javascript js library model models node nodejs typescript web
Last synced: about 2 months ago
JSON representation
Models
- Host: GitHub
- URL: https://github.com/amaui-org/amaui-models
- Owner: amaui-org
- License: mit
- Created: 2022-02-03T12:25:56.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2024-08-03T11:37:46.000Z (5 months ago)
- Last Synced: 2024-10-29T19:19:26.556Z (2 months ago)
- Topics: amaui, back-end, backend, browser, express, front-end, frontend, javascript, js, library, model, models, node, nodejs, typescript, web
- Language: TypeScript
- Homepage: https://docs.amaui.me/library/models
- Size: 279 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
amaui Models
Models
MIT license
Production ready
UMD 4.2kb gzipped
100% test cov
Browser and Nodejs
Very simple code
Modern code
Junior friendly
Typescript
Made with :yellow_heart:
## Getting started
### Add
```sh
yarn add @amaui/models
```### Use
```javascript
import express from 'express';
import { Query, Response } from '@amaui/models';async function route(req: express.Request, res: express.Response) {
const query = Query.fromRequest(req);const response = await todoCollection.searchMany(query);
return res.status(200).json(Response.fromQuery(response));
}// etc.
```### Dev
Install
```sh
yarn
```Test
```sh
yarn test
```### Prod
Build
```sh
yarn build
```