Choosing the web s future. Peter-Paul Koch Van Lanschot, 9 February 2017

Similar documents
How to approach the web platforms. Peter-Paul Koch Nordic Competence Conference, 12 September 2015

<layer> or the ingrained habits of web development. Peter-Paul Koch HTML Special, 16 June 2016

AJAX Programming Overview. Introduction. Overview

Case study on PhoneGap / Apache Cordova

Web Development for Dinosaurs An Introduction to Modern Web Development

WebRTC: Possible? Don McGregor Research Associate MOVES Institute.

The plural of Chromium is Chromia. Peter-Paul Koch NLHTML5 Rotterdam, 19 February 2015

Viewports. Peter-Paul Koch DevReach, 13 November 2017

AngularJS Fundamentals

Mobile & More: Preparing for the Latest Design Trends

Is your JavaScript ready for the Enterprise? What does that even mean?

The plural of Chromium is Chromia. Peter-Paul Koch Mobilism, 27 March 2015

Your . A setup guide. Last updated March 7, Kingsford Avenue, Glasgow G44 3EU

RESPONSIVE WEB DESIGN IN 24 HOURS, SAMS TEACH YOURSELF BY JENNIFER KYRNIN

Evolution of the "Web

Responsive Web Design Discover, Consider, Decide

How APEXBlogs was built

JavaScript Fundamentals_

Web Server Setup Guide

Slide 1: Developer Preview

THE PRAGMATIC INTRO TO REACT. Clayton Anderson thebhwgroup.com WEB AND MOBILE APP DEVELOPMENT AUSTIN, TX

HTML 5: Fact and Fiction Nathaniel T. Schutta

Transcript for Episode 3: The Right Tool for the Job

3 Continuous Integration 3. Automated system finding bugs is better than people

Web Application with AJAX. Kateb, Faris; Ahmed, Mohammed; Alzahrani, Omar. University of Colorado, Colorado Springs

Manual Of Ios 7.1 Beta 5 Iphone 4 Performance

Ten interesting features of Google s Angular Project

Viewports. Peter-Paul Koch CSS Day, 4 June 2014

MEAP Edition Manning Early Access Program WebAssembly in Action Version 1

JavaScript Web Applications: JQuery Developers' Guide To Moving State To The Client By Alex MacCaw READ ONLINE

Templates and Databinding. SWE 432, Fall 2017 Design and Implementation of Software for the Web

When Chrome Isn t Chrome

Beginners Guide to. Sencha Touch. Joshua Morony

Build Mobile Cloud Apps Effectively Using Oracle Mobile Cloud Services (MCS)

B r o w s e r s u p p o r t

GEOweb PROPERTY VIEWER

Nodes Tech Slides - Progressive Web Apps, 2018

Installing VS Code. Instructions for the Window OS.

COPYRIGHTED MATERIAL. Getting Started with Google Analytics. P a r t

Front-End Web Developer Nanodegree Syllabus

CSC 443: Web Programming

HTML version of slides:

Treating Framework Fatigue With JavaScript

We re working full time this summer alongside 3 UCOSP (project course) students (2 from Waterloo: Mark Rada & Su Zhang, 1 from UofT: Angelo Maralit)

_APP A_541_10/31/06. Appendix A. Backing Up Your Project Files

Evaluation of Visual Fabrique (VF)

Participation Status Report STUDIO ELEMENTS I KATE SOHNG

HTML/CSS Lesson Plans

Our Hall of Fame or Shame candidate for today is the command ribbon, which was introduced in Microsoft Office The ribbon is a radically

Devel::Cover - An Introduction

How to Use New Relic Browser to Improve Your Web App s User Experience

Making sense of chaos An evaluation of the current state of information architecture for the Web

Web Designer s Manual

A pixel is not a pixel. Peter-Paul Koch SF HTML5, 6 April 2012

Credits: Some of the slides are based on material adapted from

GRITS AJAX & GWT. Trey Roby. GRITS 5/14/09 Roby - 1

The goal of this book is to teach you how to use Adobe Integrated

State of the Browsers

Speed Up Windows by Disabling Startup Programs

Simple AngularJS thanks to Best Practices

Using Development Tools to Examine Webpages

Working with Javascript Building Responsive Library apps

mismatch between what is maybe possible today and what is going on in many of today's IDEs.

A pixel is not a pixel. Peter-Paul Koch BlackBerry Jam, 6 February 2012

One of the fundamental kinds of websites that SharePoint 2010 allows

Hi! My name is Peter Rushforth. I work for Natural Resources Canada, in the Canada Centre for Mapping and Earth Observation.

If Statements, For Loops, Functions

Get Your Browser into Use Quickly!

Dental Buyers Guide 101

Digital Marketing Manager, Marketing Manager, Agency Owner. Bachelors in Marketing, Advertising, Communications, or equivalent experience

Jump to: Using AAUP Photos AAUP Logos Embedding the AAUP Twitter Feed Embedding the AAUP News Feed CREATING A WEBSITE

Datacenter Care HEWLETT PACKARD ENTERPRISE. Key drivers of an exceptional NPS score

Tips & Tricks for Microsoft Word

Developing for touch. Peter-Paul Koch Mobilism, 16 and 17 May 2013

Front End Nanodegree Syllabus

Website/Blog Admin Using WordPress

Stanko Tadić

TOP DEVELOPERS MINDSET. All About the 5 Things You Don t Know.

JavaScript and MVC Frameworks FRONT-END ENGINEERING

Widget Toolkits CS MVC

E-Guide WHAT WINDOWS 10 ADOPTION MEANS FOR IT

Chapter01.fm Page 1 Monday, August 23, :52 PM. Part I of Change. The Mechanics. of Change

FIGURING OUT WHAT MATTERS, WHAT DOESN T, AND WHY YOU SHOULD CARE

of making things look better with CSS, and you have a much better platform for interface development.

Understanding Managed Services

The name of our class will be Yo. Type that in where it says Class Name. Don t hit the OK button yet.

Wakanda Architecture. Wakanda is made up of three main components: Wakanda Server Wakanda Studio Wakanda Client Framework

ONLINE EVALUATION FOR: Company Name

ENCM 339 Fall 2017: Editing and Running Programs in the Lab

High Performance Single Page Application with Vue.js

Excel Basics Rice Digital Media Commons Guide Written for Microsoft Excel 2010 Windows Edition by Eric Miller

Publications Database

Locate it inside of your Class/DreamWeaver folders and open it up.

Northern Arizona University. Capstone Team Project. Design Document. Bit Tag. Temitope Alaga, John Dance, Joshua Frampton, Jun Rao.

Week - 01 Lecture - 04 Downloading and installing Python

Data Structures and Algorithms Dr. Naveen Garg Department of Computer Science and Engineering Indian Institute of Technology, Delhi.

How To Present Progressive Web Apps To Your Clients

Clickbank Domination Presents. A case study by Devin Zander. A look into how absolutely easy internet marketing is. Money Mindset Page 1

Programming: C ++ Programming : Programming Language For Beginners: LEARN IN A DAY! (Swift, Apps, Javascript, PHP, Python, Sql, HTML) By Os Swift

State of jquery Fall John Resig

Transcription:

Choosing the web s future Peter-Paul Koch http://quirksmode.org http://twitter.com/ppk Van Lanschot, 9 February 2017

Four problems 1. Web developers want to emulate native apps, which I think is not possible 2.This causes browser vendors to add more and more features 3.Also, we get more tools that become a problem instead of solving one 4.People who re new to the web often think the web is just one platform

Emulating native apps

What went before In 2006-8, several successful web apps were built that emulated native desktop apps; most importantly Google Docs took on Microsoft Office. Quality was generally good (enough), so this was rightfully seen as a victory for the web.

What came after After those successes, web developers thought they could do better than native mobile apps as well. This, generally speaking, has turned out not to be the case but our feature priorities and the general direction of web development still point toward ever more complicated apps

Not possible Technically, it s simple. Native apps communicate directly with the OS. Web apps communicate with the browser, which communicates with the OS. Therefore web apps will always be a bit slower and coarser than native apps.

Not possible It is impossible for the web to ever become as good as native. Sure, the web is adopting native feature after native feature, and improving performance by a lot. It will have caught up with native in I don t know, two years? But by that time native will also have progressed and we ll still be behind.

Consequences You destroy basic usability by hijacking the scrollbar. You take native functionality (scrolling, selection, links, loading) that is fast and efficient and you rewrite it with cutting edge javascript toolkits and frameworks so that it is slow and buggy and broken. You balloon your websites with megabytes of cruft. You ignore best practices. You take something that works and is complementary to your business and turn it into a liability. Baldur Bjarnason - https://www.baldurbjarnason.com/notes/media-websites-vs-facebook/

Consequences But wait Am I saying that it s all the fault of trying to emulate native apps? Not quite, though that does play a role. It s the mindset of making everything more complicated that I object to. Meanwhile, front-enders seem not to understand browsers any more. While understanding browsers is the definition of a front-ender.

Too many features

Name all features browsers added in 2016

Name all features You see? You can't browsers added in 2016

Features I think browsers are implementing too many features. This is tricky, though. It s not individual features that I object to. Most individual features are a good idea, and they solve some kind of issue. The problem is that there s so MANY of them.

Polyfills New features are frequently not supported in many (most?) browsers. So we add another polyfill. So clever! Except that it increases our tool footprint once again - possibly even without good cause. Do you REALLY need that new feature? Also, it makes web developers lazy. Why not force them to write their own? That ll teach them a lot more than just copying code.

Software market maturity Users = web developers, and not visitors! 1. Technology focus. Concentrate on the fact that it works at all. 2. Feature focus. Concentrate on new features users may need. 3. Experience focus. Concentrate on the overall experience users get. by Jared Spool

Software market maturity We ve been stuck in the feature focus phase for far too long. I d say it s time to move to the experience focus stage. I d say we want to improve the overall experience of creating websites. What does that mean? I have no clue.

Moratorium That s why I proposed a moratorium on browser features of about a year. During that year, browsers may not implement new features. However, browsers are allowed to copy features other browsers already support and write bug fixes while developers learn the previous set of features

Stifling innovation Won t a moratorium stifle web innovation? Well yes, it would. In fact, that s the point. Since web innovation is currently defined as making the web even more app-like it could do with some stifling. Until we ve given the whole thing a little more thought.

Too many tools

Speed The web has a speed problem, especially on mobile. Ads are part of the problem. Or rather, maybe not even the ads themselves, but the associated scripts. The other part of the problem is the tools we use. We re using way too many of them.

http://www.nytimes.com/interactive/2015/10/01/business/cost-of-mobile-ads.html

Even without ads

Tools React and React DOM for DOM manipulation and Babel for transpiling that cool ES6 and Browserify for module management and Gulp for managing these tasks and Typescript for typed variables; and so that you have something to transpile yaddah yaddah yaddah Many thanks to Jose Aguinaga https://hackernoon.com/how-it-feels-to-learn-javascript-in-2016-d3a717dd577f#.kp42xdqrz

Tools React and React DOM for DOM manipulation and Babel for transpiling that cool ES6 and Browserify This for is module INSANE management and Gulp for managing these tasks and Typescript for typed variables; and so that you have something to transpile yaddah yaddah yaddah

We have the best libraries! Our libraries are huuuuge!jose Aguinaga

Why so many? I think we re using this many tools because we want to show web app development is a Serious Thing and Serious Developers use long toolchains but these long toolchains run on a server except on the web, where we force all of our users to run them even when they re on a crappy mobile phone

Anatomy of library use 1. Browser must download the library. This is not a huge problem, since authors have been well aware of this fact for years 2. Then the library must be initialised. This is commonly forgotten

Library initialisation Take an Android phone and measure its battery power consumption Load a mobile Wikipedia page. It uses jquery for its show/hide script. Then replace jquery by a five-line custom script. 30% power saving. 30%! Just for a library you don t need! http://crypto.stanford.edu/~dabo/papers/browserpower.pdf

Anatomy of library use 1. Browser must download library. This is not a huge problem, since authors have been well aware of this fact for years 2. Then the library must be initialised. This is commonly forgotten

Anatomy of library use 1. Browser must download library. This is not a huge problem, since authors have been well aware of this fact for years 2. Then the library must be initialised. This is commonly forgotten 3. Then the library might need to parse the DOM.

Library DOM parsing <span id= complexid1 >{{item.name}}</span> {{item.value}}<br>{{item.price}} This sort of code belongs on the server. If a library uses it it s not suited for front-end development. Why not? The library has to parse DOM text nodes to find these fragments, and that is the most costly operation imaginable. (Looking at you, Angular 1.x)

Library DOM parsing <span id= itemname >Placeholder</span> <span data-value= itemvalue ></span><br><span class= itemprice >Placeholder</span> Instead, libraries should require HTML elements with specific IDs, or other HTML attributes, so that they can be found without parsing the entire DOM.

Anatomy of library use 1. Browser must download library. This is not a huge problem, since authors have been well aware of this fact for years 2. Then the library must be initialised. This is commonly forgotten 3. Then the library might need to parse the DOM.

Anatomy of library use 1. Browser must download library. This is not a huge problem, since authors have been well aware of this fact for years 2. Then the library must be initialised. This is commonly forgotten 3. Then the library might need to parse the DOM 4. Now the library is ready and waits for user input - which might cause costly operations all over again, but we re aware of that

Modularization encourages over-design John Daggett

Learning When in doubt, learn CSS over any sort of tooling around CSS. Learn JavaScript instead of React or Angular or whatever other library seems hot at the moment. Learn HTML. Learn how browsers work. [ ] Focusing on the core helps you to recognize the strengths and limitations of these tools and abstractions. A developer with a solid understanding of vanilla JavaScript can shift fairly easily from React to Angular to Ember. Tim Kadlec - http://timkadlec.com/2015/09/the-fallacy-of-keeping-up/

The true JavaScripter use libraries and frameworks when you need them but study them in detail before doing so and use a single one per project be able to write a medium-complex application without any libraries or frameworks which gives you the technical background to change a library or framework if necessary

If you can t do without tools you re not a web developer

The web platforms (plural)

Browsers are the most hostile development platforms in the world Douglas Crockford

Browsers are the most hostile misunderstood development platforms in the world not quite Douglas Crockford

Web platforms I feel back-end developers underestimate the web platform, and thus front-end development because they misunderstand one crucial aspect. The web is not one platform. It is a multitude of platforms, most of which you ll never test on.

Platforms Why do back-enders expect the web to be one platform? They usually work for a manageable number of known environments, where languages, libraries, power and memory, and tools are pre-defined. They expect front-end to be just one more of those environment. Once they know JavaScript (i.e. tools) they can work on it.

Explaining the web Your application must run on the five most common Java server environments, all of which bring out a new version every six weeks uses four CDNs, two of which have bad APIs uses three sets of incompatible libraries, one of which is still in beta needs two root certificates that are deliberately incompatible

Explaining the web good documentation exists only for two Java server environments and one CDN - the rest is only sketchily documented by other developers kernel panics occur on your users computers, and not on your servers this entire landscape changes every six months

DRY DRY: DO repeat yourself! Web development requires you to repeat yourself. If you have an Ajax script that adds data to the page, make sure there s also a simple link somewhere. You write the same functionality twice. Not all software engineering principles make sense on the web because the web is not one platform

Web development We need to face the fact that software development for the web is different than any other software development. Problem: web development is not part of computer sciences, but of design. Because Real Computer Scientists don t do web. That s for amateurs. They refuse to learn about browsers. And without browser knowledge you can t be a web developer.

We re going wrong

Four problems 1. Web developers want to emulate native apps, which I think is not possible. 2.This causes browser vendors to add more and more features. 3.Also, we get more tools that become a problem instead of solving one 4.People who re new to the web often think the web is just one platform

Emulating native More features More tools One platform

Emulating native More features We need more features More tools One platform

Emulating native More features We need more polyfills More tools One platform

Emulating native More features Hey, the web must be mature. More tools One platform

Emulating native More features Let s impress the Serious Developers! More tools One platform

The web s strengths Let s address our featuritis. That doesn t mean ditching all tools and features. Instead, it means thinking about how each individual tool and feature furthers the web s core strengths: URLs Reach Simplicity

Thank you I ll put these slides online Questions? Peter-Paul Koch http://quirksmode.org http://twitter.com/ppk Van Lanschot, 9 February 2017