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
Building a production-ready front-end even if y...
Search
Alexandre Santos
January 09, 2020
Programming
1
110
Building a production-ready front-end even if your API does not exist
require('lx')
Alexandre Santos
January 09, 2020
Tweet
Share
More Decks by Alexandre Santos
See All by Alexandre Santos
Deno - Why should you care
asantos00
0
37
E2E tests with Cypress.io
asantos00
0
210
Mistakes I made writing React/Redux applications
asantos00
0
120
Other Decks in Programming
See All in Programming
AWS発のAIエディタKiroを使ってみた
iriikeita
1
140
AIを活用し、今後に備えるための技術知識 / Basic Knowledge to Utilize AI
kishida
17
4k
モバイルアプリからWebへの横展開を加速した話_Claude_Code_実践術.pdf
kazuyasakamoto
0
290
1から理解するWeb Push
dora1998
1
140
Kiroの仕様駆動開発から見えてきたAIコーディングとの正しい付き合い方
clshinji
1
180
Claude Codeで挑むOSSコントリビュート
eycjur
0
190
MCPでVibe Working。そして、結局はContext Eng(略)/ Working with Vibe on MCP And Context Eng
rkaga
5
740
Namespace and Its Future
tagomoris
6
680
tool ディレクティブを導入してみた感想
sgash708
1
160
為你自己學 Python - 冷知識篇
eddie
1
310
フロントエンドのmonorepo化と責務分離のリアーキテクト
kajitack
2
150
Zendeskのチケットを Amazon Bedrockで 解析した
ryokosuge
3
240
Featured
See All Featured
Testing 201, or: Great Expectations
jmmastey
45
7.6k
How to Ace a Technical Interview
jacobian
279
23k
Let's Do A Bunch of Simple Stuff to Make Websites Faster
chriscoyier
507
140k
Evolution of real-time – Irina Nazarova, EuRuKo, 2024
irinanazarova
8
910
Typedesign – Prime Four
hannesfritz
42
2.8k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Java REST API Framework Comparison - PWX 2021
mraible
33
8.8k
Practical Orchestrator
shlominoach
190
11k
Documentation Writing (for coders)
carmenintech
73
5k
Building a Scalable Design System with Sketch
lauravandoore
462
33k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
234
17k
A designer walks into a library…
pauljervisheath
207
24k
Transcript
Alexandre Santos Production-ready front-end even if the API does not
exist 9th January 2020
Who am I? Alexandre Santos, 25 January 9th 2020 Full-stack
developer Software architecture, TDD, product
Develop an amazing user experience Against a finished and documented
API That's always stable With fully decided feature requirements Front-end
None
The goal Develop an amazing user experience
Against an almost finished & not documented API That's probably
unstable With fast changing feature requirements The Conditions
None
Problems Not finished API Unstable remote environment Fast changing requirements
Problems Front-end ahead of back-end Local environment Emulate back-end changes
locally Solutions Not finished API Unstable remote environment Fast changing requirements
Possible solution Local mocks
Advantages of local mocks Quickly develop and ship the working
front-end to a testing environment. Develop for the happy path seamlessly Payload is exactly what front-end needs
Taking a few steps back... Develop an amazing user experience
Flickering UI No loading states Possible unknown crashes No feedback
given to the user Amazing user experience?
Disadvantages of local mocks Ignoring network Only develop for the
happy path APIs can change, paths can change Loading states? Error scenarios? Feedback to the user?
Presenting Mirage JS Mirage JS is an API mocking library
that lets you build, test and share a complete working JavaScript application without having to rely on any backend services.
Started with ember.js in 2015 - ember-cli-mirage Front-end first development
Widely used (around 30k weekly) Recently extracted to a vanilla JS package A little bit of history
Demo time
Problems Front-end ahead of back-end Local environment Emulate back-end changes
locally Solutions Not finished API Unstable remote environment Fast changing requirements ✅ ✅ ✅
Future ideas Node.js support Better TypeScript typings Chaos Engineering approach
to miragejs OpenAPI miragejs generator
We’d love your help! miragejs/miragejs miragejs/website miragejs-caos miragejs-open-api [insert your
package] Join us on Discord Mirage JS
Thank you Questions? Github: asantos00 Twitter: ampsantos0