Skip to content
This repository was archived by the owner on Nov 13, 2021. It is now read-only.

Commit 173254a

Browse files
committed
docs(README): update
1 parent 7fd2212 commit 173254a

File tree

1 file changed

+5
-30
lines changed

1 file changed

+5
-30
lines changed

README.md

Lines changed: 5 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,6 @@ export function handler(event) {
6464
- babel & webpack caching
6565
- node_modules are split into a single `vendor.js` file. Allowing you to debug your own code in AWS console most of the time
6666

67-
- ⚠️ the only configuration file from your project that we will read is `tsconfig.json`. Other files won't be used. If you need to reuse part of your babel configuration, please open an issue with details on your usecase.
68-
6967
## Why?
7068

7169
There's already a dedicated [aws-lambda-nodejs module for CDK](https://docs.aws.amazon.com/cdk/api/latest/docs/aws-lambda-nodejs-readme.html) but I had two major issues with it:
@@ -75,30 +73,11 @@ There's already a dedicated [aws-lambda-nodejs module for CDK](https://docs.aws.
7573

7674
I want to be clear: I respect a LOT the work of the CDK team, and especially [@jogold](https://github.com/jogold/), author of aws-lambda-nodejs) that helped me a lot into debugging performance issues and explaining to me how everything works.
7775

78-
## Roadmap
79-
80-
This is a list of features I thought could be interesting to users. If you need on of them, please contribute to the project.
81-
82-
- [ ] Test/Get feedback on TypeScript support
83-
- [ ] Get feedback on monorepo support
84-
- [ ] Allow passing webpack/babel options/a function that can update the full webpack configuration
85-
- [ ] Allow native modules/passing externals, with option `nativeModules` or `externals`. They would have to be installed into a temp folder with `npm_config_arch` and `npm_config_platform` and aliased in webpack configuration/or considered as externals. Externals and nativeModules seems related options but may be completely different
86-
- [ ] Use [jsii](https://github.com/aws/jsii) to build the construct for other languages
87-
- [ ] Add tests
88-
- [ ] (if current way buggy): force people to provide aliases instead of considering cwd as base node_module
89-
- [ ] Allow usage without the need of `entry`: `new NodejsFunction(this, "slack-notifications-lambda");` that would mimic https://docs.aws.amazon.com/cdk/api/latest/docs/aws-lambda-nodejs-readme.html#nodejs-function
90-
- [ ]
91-
- [x] Generate a bundle where entry is moved to /main.js
92-
- [x] Allow using TypeScript
93-
- [x] use webpack and babel cache
94-
- [x] remove webpackconfig from bundle
95-
- [x] pass runtime to babel target
96-
- [x] cdk synth generates different builds even when the lambda code does not changes, issue?
97-
- [x] Allow using babel, if you need preset-env
98-
- [x] add babel preset env by default
99-
- [ ] ~add bundling timing information to output console~ note: this would pollute cdk synth
100-
- [ ] ~Ask CDK team if this could live under their repositories~ Better be just community based
101-
- [ ] Other ideas? Open an issue
76+
## Caveats
77+
78+
⚠️ the only configuration file from your project that we will read is `tsconfig.json` (not including compilerOptions, which are overwritten using https://www.npmjs.com/package/@tsconfig/node12).
79+
80+
Other files won't be used (example: .babelrc). If you need to reuse part of your babel configuration, please open an issue with details on your usecase so we can build the best API for how to do this.
10281

10382
## How to make changes and test locally
10483

@@ -114,10 +93,6 @@ yarn link aws-lambda-nodejs-webpack
11493
# cdk commands will now use your local aws-lambda-nodejs-webpack
11594
```
11695

117-
## WTF happened to the rollup version?
118-
119-
In case you starred this project early on, it was previously using [rollup.js](https://rollupjs.org/) to build lambdas. After hitting roadblocks along the way, for example rollup cannot handle well circular dependencies well, I decided to stop trying to use rollup. Rollup is great to build libraries, but not so great to build web applications. And lambdas are closer to web applications bundling than libraries.
120-
12196
## Thanks
12297

12398
- the CDK team for this awesome project

0 commit comments

Comments
 (0)