Lock in $30 Savings on PRO—Offer Ends Soon! ⏳
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
140
Other Decks in Programming
See All in Programming
開発に寄りそう自動テストの実現
goyoki
1
640
Microservices rules: What good looks like
cer
PRO
0
720
無秩序からの脱却 / Emergence from chaos
nrslib
2
12k
非同期処理の迷宮を抜ける: 初学者がつまづく構造的な原因
pd1xx
1
640
Reactive Thinking with Signals and the new Resource API
manfredsteyer
PRO
0
160
UIデザインに役立つ 2025年の最新CSS / The Latest CSS for UI Design 2025
clockmaker
18
6.9k
20 years of Symfony, what's next?
fabpot
2
320
CloudNative Days Winter 2025: 一週間で作る低レイヤコンテナランタイム
ternbusty
7
2k
AIエンジニアリングのご紹介 / Introduction to AI Engineering
rkaga
3
1.3k
俺流レスポンシブコーディング 2025
tak_dcxi
13
8.1k
Building AI Agents with TypeScript #TSKaigiHokuriku
izumin5210
6
1.2k
関数実行の裏側では何が起きているのか?
minop1205
1
630
Featured
See All Featured
Why You Should Never Use an ORM
jnunemaker
PRO
60
9.6k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
36
6.2k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
31
2.7k
Navigating Team Friction
lara
191
16k
Into the Great Unknown - MozCon
thekraken
40
2.2k
Raft: Consensus for Rubyists
vanstee
140
7.2k
Sharpening the Axe: The Primacy of Toolmaking
bcantrill
46
2.6k
Speed Design
sergeychernyshev
33
1.4k
Facilitating Awesome Meetings
lara
57
6.7k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
249
1.3M
Building Adaptive Systems
keathley
44
2.9k
Intergalactic Javascript Robots from Outer Space
tanoku
273
27k
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