@aws/nx-plugin 0.18.1 → 0.18.2
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.
- package/README.md +128 -37
- package/package.json +1 -1
- package/src/utils/versions.d.ts +2 -2
- package/src/utils/versions.js +1 -1
- package/src/utils/versions.js.map +1 -1
package/README.md
CHANGED
|
@@ -1,63 +1,154 @@
|
|
|
1
|
-
|
|
1
|
+
<div align="center">
|
|
2
|
+
<h1>NX plugin for AWS - @aws/nx-plugin</h1>
|
|
3
|
+
<h3>Quickly bootstrap and build AWS projects easily</h3>
|
|
4
|
+
<a href="https://opensource.org/licenses/Apache-2.0">
|
|
5
|
+
<img
|
|
6
|
+
src="https://img.shields.io/badge/License-Apache%202.0-yellowgreen.svg"
|
|
7
|
+
alt="Apache 2.0 License"
|
|
8
|
+
/>
|
|
9
|
+
</a>
|
|
10
|
+
<a href="https://codecov.io/gh/awslabs/nx-plugin-for-aws">
|
|
11
|
+
<img src="https://codecov.io/gh/awslabs/nx-plugin-for-aws/graph/badge.svg?token=X27pgFfxuQ" />
|
|
12
|
+
</a>
|
|
13
|
+
<a href="https://gitpod.io/new/?workspaceClass=g1-large#https://github.com/awslabs/nx-plugin-for-aws">
|
|
14
|
+
<img
|
|
15
|
+
src="https://img.shields.io/badge/Gitpod-ready--to--code-blue?logo=gitpod"
|
|
16
|
+
alt="Gitpod ready-to-code"
|
|
17
|
+
/>
|
|
18
|
+
</a>
|
|
19
|
+
<a href="https://github.com/awslabs/nx-plugin-for-aws/actions/workflows/ci.yml">
|
|
20
|
+
<img
|
|
21
|
+
src="https://github.com/awslabs/nx-plugin-for-aws/actions/workflows/ci.yml/badge.svg"
|
|
22
|
+
alt="Release badge"
|
|
23
|
+
/>
|
|
24
|
+
</a>
|
|
25
|
+
<a href="https://github.com/awslabs/nx-plugin-for-aws/commits/main">
|
|
26
|
+
<img
|
|
27
|
+
src="https://img.shields.io/github/commit-activity/w/awslabs/nx-plugin-for-aws"
|
|
28
|
+
alt="Commit activity"
|
|
29
|
+
/>
|
|
30
|
+
</a>
|
|
31
|
+
<br />
|
|
32
|
+
<br />
|
|
33
|
+
<figure>
|
|
34
|
+
<img src="docs/src/content/docs/assets/website-generator.gif" alt="Demo" />
|
|
35
|
+
</figure>
|
|
36
|
+
👉 See full documentation on <a href="https://awslabs.github.io/nx-plugin-for-aws">https://awslabs.github.io/nx-plugin-for-aws</a> 👈
|
|
37
|
+
</div>
|
|
38
|
+
|
|
39
|
+
## Intro
|
|
40
|
+
|
|
41
|
+
[@aws/nx-plugin](https://github.com/awslabs/nx-plugin-for-aws) is a collection of generators to help you build cloud-native applications with AWS.
|
|
42
|
+
|
|
43
|
+
## Key Features
|
|
44
|
+
|
|
45
|
+
- **Declarative**: Generate code that follows best practices for AWS cloud development.
|
|
46
|
+
- **Component-Based**: Add components to your project as needed, from React websites to serverless APIs using either the CLI or UI.
|
|
47
|
+
- **Learn Once, Use Anywhere**: Consistent patterns across different AWS services and application types.
|
|
48
|
+
- **Open for modification**: All code generated is your code and can be edited as you see fit.
|
|
49
|
+
- **Type safety**: Type-safety is employed to support IDE completions and reduce the number of runtime errors encountered.
|
|
50
|
+
- **Minimal dependencies**: Getting up and running is simple and only requires langugage level global dependencies.
|
|
2
51
|
|
|
3
|
-
|
|
52
|
+
## Available Generators
|
|
4
53
|
|
|
5
|
-
|
|
54
|
+
- `ts#project` - Generate a new TypeScript library.
|
|
55
|
+
- `ts#infra` - Generate a Typescript AWS CDK infrastructure project for your application.
|
|
56
|
+
- `ts#cloudscape-website` - Generate a new Cloudscape/React/Vite based web application.
|
|
57
|
+
- `ts#cloudscape-website#auth` - Add AWS Cognito authentication to your Cloudscape website.
|
|
58
|
+
- `ts#trpc-api` - Generate a tRPC backend service with Amazon API Gateway/AWS Lambda integration and [AWS Powertools](https://github.com/aws-powertools/powertools-lambda-typescript) pre-configured.
|
|
59
|
+
- `py#project` - Generate a uv based Python project.
|
|
60
|
+
- `py#fast-api` - Generate a FastAPI backend service with [AWS Powertools](https://github.com/aws-powertools/powertools-lambda-python) pre-configured.
|
|
61
|
+
- `py#lambda-function` - Add a lambda function to an existing python project with optional type-safe event sources.
|
|
62
|
+
- `api-connection` - Connect frontend applications to backend APIs.
|
|
63
|
+
- `license` - Automatically manage LICENSE files and source code headers in your workspace.
|
|
6
64
|
|
|
7
|
-
|
|
65
|
+
## Getting started
|
|
8
66
|
|
|
9
|
-
|
|
10
|
-
2. Creates new files from templates
|
|
11
|
-
3. Updates existing files when needed
|
|
12
|
-
4. Follows project conventions automatically
|
|
67
|
+
@aws/nx-plugin has been designed for gradual adoption from the start, and **you can use as little or as much of it as you need**.
|
|
13
68
|
|
|
14
|
-
|
|
69
|
+
1. Create a new NX workspace
|
|
15
70
|
|
|
16
|
-
|
|
71
|
+
```bash
|
|
72
|
+
npx create-nx-workspace@~20.6.3 demo --pm=pnpm --preset=ts --ci=skip --formatter=prettier
|
|
73
|
+
cd demo
|
|
74
|
+
```
|
|
17
75
|
|
|
18
|
-
|
|
76
|
+
2. Install the `@aws/nx-plugin`
|
|
19
77
|
|
|
20
|
-
|
|
78
|
+
```bash
|
|
79
|
+
pnpm add -Dw @aws/nx-plugin
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
3. Add components:
|
|
21
83
|
|
|
22
84
|
```bash
|
|
23
|
-
|
|
85
|
+
# Generate a tRPC API backend
|
|
86
|
+
pnpm nx g @aws/nx-plugin:ts#trpc-api
|
|
87
|
+
|
|
88
|
+
# Generate a Cloudscape website
|
|
89
|
+
pnpm nx g @aws/nx-plugin:ts#cloudscape-website
|
|
90
|
+
|
|
91
|
+
# Connect the frontend to the backend
|
|
92
|
+
pnpm nx g @aws/nx-plugin:api-connection
|
|
93
|
+
|
|
94
|
+
# Add authentication to your website
|
|
95
|
+
pnpm nx g @aws/nx-plugin:ts#cloudscape-website#auth
|
|
96
|
+
|
|
97
|
+
# Generate AWS CDK infrastructure
|
|
98
|
+
pnpm nx g @aws/nx-plugin:ts#infra
|
|
24
99
|
```
|
|
25
100
|
|
|
26
|
-
###
|
|
101
|
+
### Additional resources
|
|
27
102
|
|
|
28
|
-
|
|
103
|
+
- Use [Quick Start](https://awslabs.github.io/nx-plugin-for-aws/get_started/quick-start/) to get a taste of @aws/nx-plugin.
|
|
104
|
+
- [Build a Dungeon Adventure Game](https://awslabs.github.io/nx-plugin-for-aws/get_started/tutorials/dungeon-game/overview/) to get an in-depth guided tutorial on how to use the @aws/nx-plugin.
|
|
105
|
+
- [Add @aws/nx-plugin to your existing project](https://awslabs.github.io/nx-plugin-for-aws/get_started/tutorials/existing-project/)
|
|
29
106
|
|
|
30
|
-
|
|
31
|
-
- JetBrains IDEs: [Nx Console for JetBrains](https://plugins.jetbrains.com/plugin/21060-nx-console)
|
|
107
|
+
## Documentation Translation
|
|
32
108
|
|
|
33
|
-
The
|
|
34
|
-
- Interactive generator configuration
|
|
35
|
-
- Command autocompletion
|
|
36
|
-
- Visual project graph
|
|
37
|
-
- Integrated task runner
|
|
109
|
+
The project supports automatic translation of documentation using AWS Bedrock's Deepseek & Haiku 3.5 models. Documentation is translated from English to multiple languages (currently Japanese, with support for French, Spanish, German, Chinese, and Korean).
|
|
38
110
|
|
|
39
|
-
|
|
111
|
+
> **_NOTE:_** It is important that only files in english (en folder) are modified directly as the translated files are generating using english as a base.
|
|
40
112
|
|
|
41
|
-
|
|
113
|
+
### Running Translations Locally
|
|
42
114
|
|
|
43
|
-
|
|
115
|
+
> **_NOTE:_** Ensure you have your aws cli configured to an AWS account with DeepSeek/Haiku 3.5 Bedrock model access before continuing.
|
|
116
|
+
|
|
117
|
+
To translate documentation locally:
|
|
118
|
+
|
|
119
|
+
```bash
|
|
120
|
+
# Translate only changed files
|
|
121
|
+
pnpm tsx ./scripts/translate.ts
|
|
122
|
+
|
|
123
|
+
# Translate all files
|
|
124
|
+
pnpm tsx ./scripts/translate.ts --all
|
|
125
|
+
|
|
126
|
+
# Translate to specific languages
|
|
127
|
+
pnpm tsx ./scripts/translate.ts --languages jp,fr,es
|
|
128
|
+
|
|
129
|
+
# Show what would be translated without actually translating
|
|
130
|
+
pnpm tsx ./scripts/translate.ts --dry-run
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
### GitHub Workflow
|
|
134
|
+
|
|
135
|
+
A GitHub workflow automatically translates documentation when changes are made to English documentation files in pull requests. The workflow:
|
|
44
136
|
|
|
45
|
-
|
|
137
|
+
1. Detects changes to English documentation files
|
|
138
|
+
2. Translates the changed files using DeepSeek and Haiku 3.5 on AWS Bedrock
|
|
139
|
+
3. Commits the translations back to the source branch
|
|
140
|
+
4. Updates the PR with files translated
|
|
46
141
|
|
|
47
|
-
|
|
48
|
-
- [Cognito Authentication](src/cloudscape-website/cognito-auth/README.md) - Add AWS Cognito authentication to your Cloudscape website
|
|
49
|
-
- [Runtime Configuration](src/cloudscape-website/runtime-config/README.md) - Add runtime configuration capabilities to your Cloudscape website
|
|
142
|
+
## Contributing
|
|
50
143
|
|
|
51
|
-
|
|
144
|
+
The main purpose of this repository is to continue evolving @aws/nx-plugin, making it faster and easier to use. Development happens in the open on GitHub, and we are grateful to the community for contributing bugfixes and improvements.
|
|
52
145
|
|
|
53
|
-
|
|
146
|
+
Read our [Contributing Guide](/CONTRIBUTING.md) to learn about our development process, how to propose bugfixes and improvements, and how to build and test your changes to @aws/nx-plugin.
|
|
54
147
|
|
|
55
|
-
|
|
148
|
+
## Code of Conduct
|
|
56
149
|
|
|
57
|
-
|
|
58
|
-
- [tRPC React](src/trpc/react/README.md) - Add tRPC client integration to your React application
|
|
150
|
+
This project has adopted a Code of Conduct that we expect project participants to adhere to. Please read the [Code of Conduct](/CODE_OF_CONDUCT.md) so that you can understand what actions will and will not be tolerated.
|
|
59
151
|
|
|
60
|
-
|
|
152
|
+
## License
|
|
61
153
|
|
|
62
|
-
- [
|
|
63
|
-
- [CJS to ESM](src/ts/cjs-to-esm/README.md) - Convert CommonJS modules to ECMAScript modules
|
|
154
|
+
@aws/nx-plugin is [Apache 2.0 licensed](/LICENSE).
|
package/package.json
CHANGED
package/src/utils/versions.d.ts
CHANGED
|
@@ -17,7 +17,7 @@ export declare const VERSIONS: {
|
|
|
17
17
|
readonly '@cloudscape-design/board-components': "^3.0.94";
|
|
18
18
|
readonly '@cloudscape-design/components': "^3.0.928";
|
|
19
19
|
readonly '@cloudscape-design/global-styles': "^1.0.38";
|
|
20
|
-
readonly '@tanstack/react-query': "
|
|
20
|
+
readonly '@tanstack/react-query': "5.74.2";
|
|
21
21
|
readonly '@trpc/tanstack-react-query': "11.0.0";
|
|
22
22
|
readonly '@trpc/client': "11.0.0";
|
|
23
23
|
readonly '@trpc/server': "11.0.0";
|
|
@@ -44,5 +44,5 @@ export declare const VERSIONS: {
|
|
|
44
44
|
* Add versions to the given dependencies
|
|
45
45
|
*/
|
|
46
46
|
export declare const withVersions: (deps: (keyof typeof VERSIONS)[]) => {
|
|
47
|
-
[k: string]: "^0.0.60" | "^2.185.0-alpha.0" | "^3.775.0" | "^2.17.0" | "^20.12.0" | "^1.114.27" | "^3.0.94" | "^3.0.928" | "^1.0.38" | "
|
|
47
|
+
[k: string]: "^0.0.60" | "^2.185.0-alpha.0" | "^3.775.0" | "^2.17.0" | "^20.12.0" | "^1.114.27" | "^3.0.94" | "^3.0.928" | "^1.0.38" | "5.74.2" | "11.0.0" | "^22.13.13" | "^8.10.148" | "^4.2.0" | "^1.0.20" | "^2.1006.0" | "^2.185.0" | "^3.10.3" | "^10.4.2" | "^0.25.1" | "^5.2.5" | "^2.4.0" | "^3.2.0" | "^3.5.3" | "^0.5.21" | "^4.19.3" | "^5.1.4" | "^3.24.2";
|
|
48
48
|
};
|
package/src/utils/versions.js
CHANGED
|
@@ -20,7 +20,7 @@ exports.VERSIONS = {
|
|
|
20
20
|
'@cloudscape-design/board-components': '^3.0.94',
|
|
21
21
|
'@cloudscape-design/components': '^3.0.928',
|
|
22
22
|
'@cloudscape-design/global-styles': '^1.0.38',
|
|
23
|
-
'@tanstack/react-query': '
|
|
23
|
+
'@tanstack/react-query': '5.74.2', // TODO: https://github.com/awslabs/nx-plugin-for-aws/issues/147
|
|
24
24
|
'@trpc/tanstack-react-query': '11.0.0',
|
|
25
25
|
'@trpc/client': '11.0.0',
|
|
26
26
|
'@trpc/server': '11.0.0',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"versions.js","sourceRoot":"","sources":["../../../../../packages/nx-plugin/src/utils/versions.ts"],"names":[],"mappings":";;;AAAA;;;GAGG;AACU,QAAA,QAAQ,GAAG;IACtB,iCAAiC,EAAE,SAAS;IAC5C,yCAAyC,EAAE,kBAAkB;IAC7D,kCAAkC,EAAE,UAAU;IAC9C,+BAA+B,EAAE,UAAU;IAC3C,+CAA+C,EAAE,UAAU;IAC3D,+BAA+B,EAAE,SAAS;IAC1C,gCAAgC,EAAE,SAAS;IAC3C,+BAA+B,EAAE,SAAS;IAC1C,cAAc,EAAE,UAAU;IAC1B,wBAAwB,EAAE,WAAW;IACrC,yBAAyB,EAAE,WAAW;IACtC,qCAAqC,EAAE,SAAS;IAChD,+BAA+B,EAAE,UAAU;IAC3C,kCAAkC,EAAE,SAAS;IAC7C,uBAAuB,EAAE,
|
|
1
|
+
{"version":3,"file":"versions.js","sourceRoot":"","sources":["../../../../../packages/nx-plugin/src/utils/versions.ts"],"names":[],"mappings":";;;AAAA;;;GAGG;AACU,QAAA,QAAQ,GAAG;IACtB,iCAAiC,EAAE,SAAS;IAC5C,yCAAyC,EAAE,kBAAkB;IAC7D,kCAAkC,EAAE,UAAU;IAC9C,+BAA+B,EAAE,UAAU;IAC3C,+CAA+C,EAAE,UAAU;IAC3D,+BAA+B,EAAE,SAAS;IAC1C,gCAAgC,EAAE,SAAS;IAC3C,+BAA+B,EAAE,SAAS;IAC1C,cAAc,EAAE,UAAU;IAC1B,wBAAwB,EAAE,WAAW;IACrC,yBAAyB,EAAE,WAAW;IACtC,qCAAqC,EAAE,SAAS;IAChD,+BAA+B,EAAE,UAAU;IAC3C,kCAAkC,EAAE,SAAS;IAC7C,uBAAuB,EAAE,QAAQ,EAAE,gEAAgE;IACnG,4BAA4B,EAAE,QAAQ;IACtC,cAAc,EAAE,QAAQ;IACxB,cAAc,EAAE,QAAQ;IACxB,aAAa,EAAE,WAAW;IAC1B,mBAAmB,EAAE,WAAW;IAChC,eAAe,EAAE,QAAQ;IACzB,SAAS,EAAE,SAAS;IACpB,SAAS,EAAE,WAAW;IACtB,aAAa,EAAE,UAAU;IACzB,mBAAmB,EAAE,SAAS;IAC9B,UAAU,EAAE,SAAS;IACrB,OAAO,EAAE,SAAS;IAClB,wBAAwB,EAAE,QAAQ;IAClC,qBAAqB,EAAE,QAAQ;IAC/B,gBAAgB,EAAE,QAAQ;IAC1B,QAAQ,EAAE,QAAQ;IAClB,oBAAoB,EAAE,QAAQ;IAC9B,oBAAoB,EAAE,SAAS;IAC/B,GAAG,EAAE,SAAS;IACd,qBAAqB,EAAE,QAAQ;IAC/B,GAAG,EAAE,SAAS;CACN,CAAC;AAEX;;GAEG;AACI,MAAM,YAAY,GAAG,CAAC,IAA+B,EAAE,EAAE,CAC9D,MAAM,CAAC,WAAW,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC,GAAG,EAAE,gBAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC;AADjD,QAAA,YAAY,gBACqC"}
|