@nestia/sdk 1.1.0-dev.20230420 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/README.md +36 -63
  2. package/package.json +5 -5
package/README.md CHANGED
@@ -1,82 +1,55 @@
1
- # Nestia SDK Generator
1
+ # Nestia
2
+ ![Nestia Logo](https://nestia.io/logo.png)
3
+
2
4
  [![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://github.com/samchon/nestia/blob/master/LICENSE)
3
- [![npm version](https://img.shields.io/npm/v/@nestia/sdk.svg)](https://www.npmjs.com/package/@nestia/sdk)
4
- [![Downloads](https://img.shields.io/npm/dm/@nestia/sdk.svg)](https://www.npmjs.com/package/@nestia/sdk)
5
- [![Build Status](https://github.com/samchon/typia/workflows/build/badge.svg)](https://github.com/samchon/nestia/actions?query=workflow%3Abuild)
6
- [![Guide Documents](https://img.shields.io/badge/wiki-documentation-forestgreen)](https://github.com/samchon/nestia/wiki)
5
+ [![npm version](https://img.shields.io/npm/v/@nestia/core.svg)](https://www.npmjs.com/package/@nestia/core)
6
+ [![Downloads](https://img.shields.io/npm/dm/nestia.svg)](https://www.npmjs.com/package/nestia)
7
+ [![Build Status](https://github.com/samchon/nestia/workflows/build/badge.svg)](https://github.com/samchon/nestia/actions?query=workflow%3Abuild)
8
+ [![Guide Documents](https://img.shields.io/badge/guide-documents-forestgreen)](https://nestia.io/docs/)
7
9
 
8
- Automatic *SDK* and *Swagger* generator for `@nestia/core`.
10
+ Nestia is a set of helper libraries for NestJS, supporting below features:
9
11
 
10
- With `@nestia/core`, you can boost up validation speed maximum **15,000x times faster**. However, as `@nestjs/swagger` does not support `@nestia/core`, you can't generate swagger documents from `@nestjs/swagger` more.
12
+ - `@nestia/core`: super-fast decorators
13
+ - `@nestia/sdk`: evolved SDK and Swagger generator
14
+ - `nestia`: just CLI (command line interface) tool
11
15
 
12
- Instead, I provide you `@nestia/sdk` module, which can generate not only swagger documents, but also SDK (Software Development Kit) library.
16
+ > **Note**
17
+ >
18
+ > - **Only one line** required, with pure TypeScript type
19
+ > - Runtime validator is **20,000x faster** than `class-validator`
20
+ > - JSON serialization is **200x faster** than `class-transformer`
21
+ > - SDK is similar with [tRPC](https://trpc.io), but much advanced
13
22
 
14
23
  ![nestia-sdk-demo](https://user-images.githubusercontent.com/13158709/215004990-368c589d-7101-404e-b81b-fbc936382f05.gif)
15
24
 
25
+ > Left is server code, and right is client code utilizing SDK
16
26
 
17
27
 
18
28
 
19
- ## Setup
20
- ### Boilerplate Project
21
- ```bash
22
- npx nestia start <directory>
23
- ```
24
-
25
- Just run above command, then boilerplate project would be constructed.
26
-
27
- ### Setup Wizard
28
- ```bash
29
- npx nestia setup
30
- ```
31
-
32
- When you want to use `nestia` in orindary project, just type above command.
33
-
34
- All installation and configuration processes would be automatically done.
35
-
36
- Also, you can specify package manager by `--manage` argument like below:
37
-
38
- ```bash
39
- npx nestia setup --manager npm
40
- npx nestia setup --manager pnpm
41
- npx nestia setup --manager yarn
42
- ```
43
-
44
- ### Sole Setup
45
- If you want to install and setup `@nestia/sdk` only, just do it.
46
-
47
- ```bash
48
- npm install --save-dev @nestia/sdk
49
- ```
50
-
51
29
 
30
+ ## Sponsors and Backers
31
+ Thanks for your support.
52
32
 
33
+ Your donation would encourage `nestia` development.
53
34
 
54
- ## Usage
55
- ```bash
56
- # BASIC COMMAND
57
- npx nestia <sdk|swagger> <source_directories_or_patterns> \
58
- --exclude <exclude_directory_or_pattern> \
59
- --out <output_directory_or_file>
35
+ [![Backers](https://opencollective.com/nestia/backers.svg?avatarHeight=75&width=600)](https://opencollective.com/nestia)
60
36
 
61
- # EXAMPLES
62
- npx nestia sdk "src/**/*.controller.ts" --out "src/api"
63
- npx nestia swagger "src/controllers" --out "dist/swagger.json"
64
- ```
65
37
 
66
- You can generate sdk or swagger documents by above commands.
67
38
 
68
- If you've configured `nestia.config.ts` file, you can omit all options like below. About the `nestia.config.ts` file, read [Guide Documents -> SDK Generator -> Configuration](https://github.com/samchon/nestia/wiki/SDK-Generator#configuration)
69
39
 
70
- ```bash
71
- npx nestia sdk
72
- npx nestia swagger
73
- ```
40
+ ## Guide Documents
41
+ Check out the document in the [website](https://nestia.io/docs/):
74
42
 
75
- If you want to know more, visit [Guide Documents](https://github.com/samchon/nestia/wiki).
43
+ ### 🏠 Home
44
+ - [Introduction](https://nestia.io/docs/)
45
+ - [Setup](https://nestia.io/docs/setup/)
76
46
 
77
- - Generators
78
- - [Swagger Documents](https://github.com/samchon/nestia/wiki/SDK-Generator#swagger-documents)
79
- - [SDK Library](https://github.com/samchon/nestia/wiki/SDK-Generator#sdk-library)
80
- - Advanced Usage
81
- - [Comment Tags](https://github.com/samchon/nestia/wiki/SDK-Generator#comment-tags)
82
- - [Configuration](https://github.com/samchon/nestia/wiki/SDK-Generator#configuration)
47
+ ### 📖 Features
48
+ - Core Library
49
+ - [TypedRoute](https://nestia.io/docs/core/TypedRoute/)
50
+ - [TypedBody](https://nestia.io/docs/core/TypedBody/)
51
+ - [TypedParam](https://nestia.io/docs/core/TypedParam/)
52
+ - [TypedQuery](https://nestia.io/docs/core/TypedRoute/)
53
+ - SDK/Swagger Generator
54
+ - [SDK Library](https://nestia.io/docs/sdk/sdk/)
55
+ - [Swagger Documents](https://nestia.io/docs/sdk/swagger/)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nestia/sdk",
3
- "version": "1.1.0-dev.20230420",
3
+ "version": "1.1.0",
4
4
  "description": "Nestia SDK and Swagger generator",
5
5
  "main": "lib/index.js",
6
6
  "typings": "lib/index.d.ts",
@@ -9,7 +9,7 @@
9
9
  },
10
10
  "scripts": {
11
11
  "build": "rimraf lib && tsc",
12
- "dev": "rimraf lib &&ttsc --watch",
12
+ "dev": "rimraf lib && tsc --watch",
13
13
  "eslint": "eslint ./**/*.ts",
14
14
  "package:latest": "npm run build && npm run test && npm publish --access public",
15
15
  "package:next": "npm run package:latest -- --tag next",
@@ -43,7 +43,7 @@
43
43
  "tsconfck": "^2.0.1",
44
44
  "tsconfig-paths": "^4.1.1",
45
45
  "tstl": "^2.5.13",
46
- "typia": "^3.8.0-dev.20230420-2"
46
+ "typia": "^3.8.1"
47
47
  },
48
48
  "peerDependencies": {
49
49
  "@nestjs/common": ">= 7.0.1",
@@ -53,8 +53,8 @@
53
53
  "typescript": ">= 4.5.2"
54
54
  },
55
55
  "devDependencies": {
56
- "@nestia/core": "^1.1.0-dev.20230420",
57
- "@nestia/fetcher": "^1.1.0-dev.20230420-2",
56
+ "@nestia/core": "^1.1.0",
57
+ "@nestia/fetcher": "^1.1.2",
58
58
  "@trivago/prettier-plugin-sort-imports": "^4.0.0",
59
59
  "@types/cli": "^0.11.21",
60
60
  "@types/express": "^4.17.15",