aws-samples / aws-sdk-js-notes-app

A simple note taking application using modular AWS SDK for JavaScript (v3)
Other
81 stars 30 forks source link

feat(backend): replace webpack with esbuild #40

Closed trivikr closed 3 years ago

trivikr commented 3 years ago

Issue

Fixes: https://github.com/aws-samples/aws-sdk-js-notes-app/issues/5

Description

Replaces webpack with esbuild in the backend.

Before ```console $ yarn build asset updateNote/app.js 216 KiB [emitted] [minimized] (name: updateNote) 1 related asset asset createNote/app.js 215 KiB [emitted] [minimized] (name: createNote) asset deleteNote/app.js 215 KiB [emitted] [minimized] (name: deleteNote) 1 related asset asset getNote/app.js 213 KiB [emitted] [minimized] (name: getNote) 1 related asset asset listNotes/app.js 211 KiB [emitted] [minimized] (name: listNotes) 1 related asset orphan modules 1.77 MiB [orphan] 274 modules runtime modules 4.58 KiB 20 modules built modules 6.98 MiB [built] cacheable modules 106 KiB javascript modules 76 KiB 18 modules json modules 30 KiB 4 modules modules by path ./src/ 6.87 MiB ./src/createNote.ts + 164 modules 1.38 MiB [not cacheable] [built] [code generated] ./src/deleteNote.ts + 164 modules 1.37 MiB [not cacheable] [built] [code generated] ./src/getNote.ts + 166 modules 1.39 MiB [not cacheable] [built] [code generated] ./src/listNotes.ts + 164 modules 1.36 MiB [not cacheable] [built] [code generated] ./src/updateNote.ts + 164 modules 1.37 MiB [not cacheable] [built] [code generated] webpack 5.19.0 compiled successfully in 12709 ms ```
After ```console $ yarn build dist/updateNote/app.js 498.4kb dist/createNote/app.js 498.4kb dist/getNote/app.js 498.3kb dist/deleteNote/app.js 498.3kb dist/listNotes/app.js 498.2kb ⚡ Done in 102ms ```

Testing

Local testing.


By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.