Slide 1

Slide 1 text

No content

Slide 2

Slide 2 text

A sneak peek at an extensible mail client N1 Evan Morikawa | [email protected] | @e0m

Slide 3

Slide 3 text

Why build a mail client?

Slide 4

Slide 4 text

Email is massive

Slide 5

Slide 5 text

~200B Emails / day (Radicati Group April 2014) ~45B WhatsApp + FB (TechCrunch. Jan 2015) ~30B WeChat (Speculative. Equivalent DAU to WhatsApp) ~40B iMessage (Tim Cook 2014) ~0.5B Tweets (Twitter 2015) ~0.7B Snapchat (Verge 2014) ~0.01B Slack (FacstCompany, Feb 2015)

Slide 6

Slide 6 text

Email is the “Database of your life”

Slide 7

Slide 7 text

Email has hundreds of uses

Slide 8

Slide 8 text

Email has hundreds of uses and old, inflexible interfaces

Slide 9

Slide 9 text

Email is very valuable, but creating new email experiences is very hard.

Slide 10

Slide 10 text

N1 Screenshot

Slide 11

Slide 11 text

Sidebar Screenshot

Slide 12

Slide 12 text

Composer Templates Screenshot

Slide 13

Slide 13 text

N1 Screenshot

Slide 14

Slide 14 text

No content

Slide 15

Slide 15 text

No content

Slide 16

Slide 16 text

Slide 17

Slide 17 text

MessageStore Dispatcher

Slide 18

Slide 18 text

Re: ReactConf Europe To: [email protected]

Slide 19

Slide 19 text

Component regions in red

Slide 20

Slide 20 text

Sidebar Screenshot

Slide 21

Slide 21 text

Next week, we’re launching N1. Hack away! Lots of docs, sample code, etc.

Slide 22

Slide 22 text

Next week, we’re open-sourcing N1. GPL v3 (Free for personal use)

Slide 23

Slide 23 text

Slide 24

Slide 24 text

Slide 25

Slide 25 text

Nylas API Platform • REST APIs for email, contacts, and calendar • Gmail, Exchange, iCloud, Yahoo, and hundreds more. • Powers email integration in CRMs, mobile apps, etc. Making email easy.

Slide 26

Slide 26 text

N1 Mail Client • Clean, minimal foundation with “must-have” features • Robust APIs for dealing with threads, messages, etc. • Cross-platform: Mac, Windows, Linux • Easy to extend with modern technologies Making email easy. Nylas API Platform

Slide 27

Slide 27 text

Why Electron? • Mac, Windows, Linux support • Great APIs for desktop integration • Support for C/C++ code via native modules • Atom = open-source sample code and tooling • Large numbers of developers know JavaScript, HTML, CSS, can write extensions easily!

Slide 28

Slide 28 text

Challenges 1. NodeJS is single-threaded 
 2. Windows live in separate processes
 3. Platform-specific styling an exercise to the reader

Slide 29

Slide 29 text

Party on the Main Thread • BrowserWindows render and run JavaScript on the same thread. • All work is created equal. Great for a web server, not so great for a desktop app. • (Web Workers don’t get NodeJS integration)

Slide 30

Slide 30 text

Party on the Main Thread • Animations • Transitions • Scrolling • User interaction • Applying mailbox changes • Running spellcheck • Downloading attachments • Running mail rules

Slide 31

Slide 31 text

Party on the Main Thread

Slide 32

Slide 32 text

Windows are process-isolated • No shared memory between windows • Messaging between windows requires hops through the parent application process • Major conceptual barrier to multi-window app development

Slide 33

Slide 33 text

Multi-window Flux Architecture Application Process Task Store ActionBridge QueueTask: Send Draft QueueTask: Send Draft ActionBridge DraftStore JSON via IPC

Slide 34

Slide 34 text

1. JavaScript is single-threaded 
 
 2. Windows live in separate processes
 
 3. Platform-specific styling an exercise to the reader Move CPU-intensive tasks to a worker window Bridge Flux stores and actions across windows Fine-tune CSS to match platform standards