Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
NestJSを活用したREST APIサーバ/REST_API_SERVER_BY_NESTJS
Search
Masahiko Sakakibara
November 29, 2019
0
1.4k
NestJSを活用したREST APIサーバ/REST_API_SERVER_BY_NESTJS
Masahiko Sakakibara
November 29, 2019
Tweet
Share
More Decks by Masahiko Sakakibara
See All by Masahiko Sakakibara
プライベートプロダクト戦略 - フロントエンドカンファレンス沖縄 / private_product_frontend
rdlabo
3
4.2k
GitHubをCMSとして使う話/ using_github_as_CMS
rdlabo
0
360
JavaScriptから デバイスの力を100%引き出すための Web APIとCapacitor入門 / power_from_javascript
rdlabo
0
480
Capacitor4_release
rdlabo
0
590
Web技術で稼ぐため選択肢を俯瞰しよう/options_to_earn_web_technology
rdlabo
0
110
Ionicモバイルアプリ制作入門/get_started_with_ionic
rdlabo
0
99
JavaScript から デバイスの力を 100%引き出すための Capacitor と Angular でのはじめかた。
rdlabo
2
1.7k
JavaScriptとSwift&JavaをつなげるCapacitorと、これからのWeb Frontend/Linking JavaScript with Swift&Java, And the future of Web Frontend.
rdlabo
0
3.6k
事例からみるアプリデザインの成長戦略とWeb Native Platform/app_design_growth
rdlabo
1
790
Featured
See All Featured
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
44
9.3k
Measuring & Analyzing Core Web Vitals
bluesmoon
4
170
"I'm Feeling Lucky" - Building Great Search Experiences for Today's Users (#IAC19)
danielanewman
226
22k
The Art of Programming - Codeland 2020
erikaheidi
53
13k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
656
59k
Site-Speed That Sticks
csswizardry
2
190
The Art of Delivering Value - GDevCon NA Keynote
reverentgeek
8
1.2k
Cheating the UX When There Is Nothing More to Optimize - PixelPioneers
stephaniewalter
280
13k
The Straight Up "How To Draw Better" Workshop
denniskardys
232
140k
How to Think Like a Performance Engineer
csswizardry
22
1.2k
CSS Pre-Processors: Stylus, Less & Sass
bermonpainter
356
29k
Designing on Purpose - Digital PM Summit 2013
jponch
116
7k
Transcript
/FTU+4Λ׆༻ͨ͠ 3&45"1*αʔό
ࣗݾհ !SEMBCP Ұൠࣾஂ๏ਓ ϦϨʔγϣϯσβΠϯݚڀॴදཧࣄ Ұൠࣾஂ๏ਓ "SFB*OOPWBUJPO"MJBODF$50 *POJD+BQBO 6TFS(SPVQද
ίϯτϦϏϡʔλʔ ionic-team/ionic ionic-team/starters ionic-team/ionic-cli ionic-team/ionic-docs ionic-team/ionic-react -conference-app GoogleChrome/lighthouse
όοΫΤϯυͱϑϩϯτΤϯυͷͭͳ͗ํ
ϨϯμϦϯάίετ͕ॏ͍ಈతαΠτ .PEFMͰσʔλΛܗͯ͠ ߹ʹΑͬͯ$PUSPMMFSͰ ͦΕΛల։ɾ࠶ܗͯ͠ 7JFXͰల։͢Δ
ΤϥʔϋϯυϦϯά͕͍͠ಈతαΠτ
ΑΓΑ͍69Λࢦͯ͠ ੩తαΠτ 4JOHMF1BHF"QQMJDBUJPO 41" 3&45"1*(SBQI2-ʹΑΔόοΫΤ ϯυͱϑϩϯτΤϯυͷϒϦοδ +BWB4DSJQUʹΑΔϦονͳ6*
1SPHSFTTJWF8FC"QQT 18" 41" 8FC"1* ಈతαΠτ ΑΓΑ͍69Λࢦ͢
+40/ͰͷΓͱΓ͕Ұൠతͳख๏ʹɻ όοΫΤϯυ \n^ ϑϩϯτΤϯυ \n^
+40/Ͱൃ͢Δͱ͍͏Ҏ্ͷใڞ༗Ͱ͖͍ͯ·͔͢ʁ όοΫΤϯυ \n^ ϑϩϯτΤϯυ \n^ ѫࡰͯ͠΄͍͠ (&5IFMMP ʁʁ 3&45Ͱɺॲཧํ๏ͱྨ͔͠ఆٛͯ͘͠Εͳ͍ɻ
ཧͷੈք όοΫΤϯυ \n^ \ OBNFTUSJOH EFTDTUSJOH JNBHFTUSJOH VSMTUSJOH ^<> ͰσʔλΛૹΔˠ
ϑϩϯτΤϯυ \n^ \ OBNFTUSJOH EFTDTUSJOH JNBHFTUSJOH VSMTUSJOH ^<> Ͱσʔλ͕ཉ͍͠ ˡ
ͦ͏ͩ5ZQF4DSJQUͩʂ w"1*ͷܕΛڞ༗Ͱ͖Δͷ5ZQF4DSJQU͚ͩʢ wFYQSFTTϑϨʔϜϫʔΫͱͯͪ͠ΐͬͱബ͍ w/FTU+4ϑϨʔϜϫʔΫͱͯ͠ͷػೳ͕े ɾ3&45"1*Λ࠾༻ͯ͠Δ ɾৄࡉυΩϡϝϯτͱͷೋॏཧΛͨ͘͠ͳ͍ ɹɹɹɹɹɹɹɹɹɹɹɹɹɹɹʜϓϩδΣΫτͰΦεεϝ 8FC"TTFNCMZͳͲͷಈ࡞ڥΛআ͖·͢
ܕͷڞ༗ʹ͍ͭͯ
͡Ό͋Ͳ͏ͬͯܕΛڞ༗͢Δʁʁ όοΫΤϯυ \n^ ϑϩϯτΤϯυ \n^ Ͳ͏ͬͯܕΛڞ༗ʁ OQNύοέʔδʹ͢Δ ˕ ཧతɻͨͩ͠อक͕खؒɻ /FTU+4ͷϓϩδΣΫτʹ
ஔ͘ ̋ ݱ࣮తɻϑϩϯτΤϯυ͔Β webpackͰόϯυϧ ϓϩδΣΫτ֎ʹ͓͘ ˚ tscίϚϯυͷઃఆΛཁมߋʢະௐࠪʣ
σϞ ʢձͰͷܕΤϥʔͷ࣮ԋʹͳΓ·͢ʣ
XFCQBDLͱUTDίϚϯυҧ͏ XFCQBDL όϯυϥʔɻUZQFTDSJQUύοέʔδΛར༻͢Δ͜ͱͰɺSFRVJSFؔ JNQPSUؔΛఏڙͯ͠ґଘؔղܾࡁΈͷγϯϓϧͳϑΝΠϧΛग़ྗ͢Δ ͜ͱ͕Ͱ͖Δɻ UTDίϚϯυ 5ZQF4DSJQU͔Β+BWB4DSJQUͷίϯύΠϧΛߦ͏ɻґଘؔग़ྗͷղܾͳ ʹͦΕɻίϯύΠϥͰ͢ɻ
CBEQSBDUJDFUPJOTUBMMEFQFOEFODJFTPOBQSPEVDUJPOTFSWFS IUUQTHJUIVCDPNHPMECFSHZPOJOPEFCFTUQSBDUJDFTJTTVFT
*EPOPUSFDPNNFOEVTJOHBOZCVOEMFSGPS/PEF IUUQTHJUIVCDPNOFTUKTOFTUJTTVFTJTTVFDPNNFOU
"1*ͳΒ࣌ؒಈ͔͞ͳ͍͍ͯ͘ͷͰ ʢ4FSWFSͷอकͨ͘͠ͳ͍ʂʣ
ৗʹΞΫηε͕͋ΔͱݶΒͳ͍ load() { if (this.data) { return of(this.data); } else
{ return this.http.get<IDataJson>(‘https://example.com‘) .pipe(map(this.processData, this)); } } ϝϞϦετϨʔδΛ ׆༻ͨ͠Γ FϥʔχϯάΈ͍ͨʹ සൟͳ"1*ߋ৽͕ͳ͍
ͦ͏ͩʂ-BNCEBͩʂʂ ʮίʔυͷอकͰखҰഋ͔ͩΒαʔόͷอकͨ͘͠ͳ͍ʯ
/PEPDTGSPN ʜͭ͘Εͦ͏͡Όͳ͍ʁ
ͭ͘Εͨɻ ࠓ.FFUVQ͋Δ͔ΒͿΓʹόʔδϣϯਵͨ͠
͍ํ $ npm install serverless -g $ git clone
[email protected]
:rdlabo/serverless-nestjs.git
ʲprojectNameʳ Πϯετʔϧ ։ൃ $ npm start -BNCEB)PUTUBSUαϙʔτ 4XBHHFSαϙʔτ $ npx ts-node src/swagger.ts
ϑϩϯτΤϯυͱόοΫΤϯυͰڞ௨ݴޠΛ खʹೖΕΑ͏ɻ ϩδΧϧʹָͰ͖Δ/FTU+4͍͍Ͱ͢Α
*POJDΛ͏ͱ8FCͰϞόΠϧΞϓϦͭ͘Ε·͢ ϒϥβ 18" J04ΞϓϦ
͜͏͍͏ΞϓϦ͕ʹͭ͘ΕΔΑ͏ʹʂ
*POJDͰ࡞ΔϞόΠϧΞϓϦ੍࡞ೖ ୯ߦຊr ϖʔδɹ ԁ IUUQTBN[OUP1"S&M