SlideShare ist ein Scribd-Unternehmen logo
1 von 169
Downloaden Sie, um offline zu lesen
Crap! It doesn’t
                 look quite right
                  Or: How I learned to stop worrying and set
                              my web sites free

         Lyza Danger Gardner / lyza@lyza.com
         @lyzadanger / Over the Air, 2011


Monday, October 3, 11
Hi, there, Bletchley
                               Park.
                          My name is Lyza.



Monday, October 3, 11
I love the web.




                                                       photo by lukew




Monday, October 3, 11

Hi, I’m Lyza. I love the web. I always have. Ever since the 1990s, when the web was just a wee
baby.
I hail from Portland.


                        Hi!




Monday, October 3, 11

I live in Portland, Oregon, USA. In fact, I was born and raised there. This is actually seriously unusual.
Portland is the kind of place people want to move to, and increasingly, it’s hard to find actual natives.
Monday, October 3, 11

In Portland, we are known for our coffee.
Monday, October 3, 11

Our beer...
Monday, October 3, 11

...and our foodie inclinations.
Portland is also famous for its
                hipsters, bikes and other stu! I don’t
                have photos of. Come visit. It’s fun.




Monday, October 3, 11

And a host of other trendy things. Portland’s grown a reputation of late and is particularly the
darling of the New York Times, which publishes fawning articles about its quaintness
regularly. As you can tell, I’m proud of the town. And it also has a strong mobile development
community.
Portland
                                                                        +
                                                                    Interwebs
                                                                        +
                                                                      mobile
                                                                        +
               Iamonateam
                         withsome
               wickedlysmart
                                                                                 }   Dramatis personae


                             people
                                                                        =
                                                                    Cloud Four


Monday, October 3, 11

So, I live in Portland, and in 2007 I helped co-found Cloud Four with three other folks I’ve
worked with for over a decade. We came from a deep “traditional” web background and we
wanted to seize on the incredibly neat opportunities provided by mobile.
Cloud Four chose the web.
                        It was in no way an easy choice.




Monday, October 3, 11
2008
                                                             Flashbackto




Monday, October 3, 11

We founded Cloud Four in 2007, with an initial vision of mobile web goodness. In 2008, a lot
of stuff happened.
As luck would have it...
                I was fortunate enough to
                be on the team that
                developed the Obama
                iPhone app.




Monday, October 3, 11
What an exciting time.
                This was a mere few
                months after the initial
                launch of the App Store.

                Everyone was very excited.




Monday, October 3, 11

This was in the late summer of 2008, mere months after the initial launch of Apple’s App
Store in the US. Everyone was basically quivering with excitement.
Now what?
               Follow the !ow and build
               native apps for a living, or
               continue to bank on the
               promise of the web?




                                                  photo by Robert Goodwin




Monday, October 3, 11

At Cloud Four, we were faced with a crossroads. Colleagues we knew and admired were
throwing in their lot with native iOS apps. Should we stick with our original dream, pinning
our hopes on what we see as a more democratic, more universal and more meaningful
technology?
What apps can do, the web can do, too...




Monday, October 3, 11

Cloud Four co-founder Jason Grigsby went over the features of the Obama application with a
fine-toothed comb. His realization here? There’s nothing in this app that couldn’t be
accomplished with web technologies.
Since then, at Cloud Four...




Monday, October 3, 11

Epiphanies like this helped us make up our minds. We stuck with the web. Since then, we’ve
built stuff.
High-performance mobile
      web applications and sites.




Monday, October 3, 11

Like Hautelook.com’s mobile site. Hautelook is a fashion flash-sale site with extreme traffic
spikes as, at 8am each morning, frantic fashion-conscious bargain-seeking shoppers
descend on the site. It is one of the top 2k sites in the world, and boy, howdy are shoppers
going to be mad if they can’t access the site because of performance problems or rendering
issues.
Web sites and
                                                          applications for both
                                                          “desktop” and
                                                          “mobile” devices and
                                                          browsers.




Monday, October 3, 11

But it’s not all about standalone mobile sites—in fact, we generally aim for the opposite. For
example, we build this full-gamut site for a local craft brewery in Oregon. There’s some neat
stuff going on here that you couldn’t do before mobile, for example, we use geolocation to
help users find the closest shop, bar, or restaurant that carries a specific brew that Deschutes
makes. Fun stuff! We love the mobile web.
The mobile web is hard.




Monday, October 3, 11

We’ve learned something. The mobile web is hard. And, frankly, instead of easing up as time
goes by, it kind of seems to be getting harder right now. Before we get down to our little chat
here, I want to take a moment to make annoying observations about linguistics.
(A brief aside)
                regarding terminology.




Monday, October 3, 11

Before we get down to our little chat here, I want to take a moment to make annoying
observations about linguistics.
“There is no mobile web.”
                                            —Jeremy Keith (@ada!io)




Monday, October 3, 11

Well-known web dude Jeremy Keith gave a presentation a few weeks ago at the Breaking
Development Conference in Nashville, Tenn. The title of his presentation was “There is no
mobile web.” At the time, I thought he was trying to stir up a bit of controversy.
At rst, I didn’t get it.




Monday, October 3, 11

Surely, this is splitting semantic hairs? But then I thought about it a bit more.
The stu# we’re up against is bigger than a pile
                                   telephones




                        photo by Dave Patten




Monday, October 3, 11

Not everything that browses the web is a desktop computer or a telephone. By referring to
the “mobile web,” we’re both ignoring the broader context and acting like there is more than
one web, when in fact the goal is universality.
So many devices.




Monday, October 3, 11

It’s about making the web fit a vast array of devices and platforms. Everyone loves
mentioning those still-odd outliers like Automobiles. Refrigerators. Wristwatches. Yes, mobile
devices like phones represent the big thrust, but the meaning is deeper.
also...




Monday, October 3, 11

Just to make things yet more complex...
What do we mean when
                          we say “device?”
                                                       device itself (hardware)
                                                                   +
             Chancesare,we            platform
              meanbitsand                  +
              botsofvarious              OS
                  things
                                                                   +
                                                               browser
                                                                   +
                                                    carrier/connectivity elements



Monday, October 3, 11

We talk about the devices that are accessing our services. In web terms, what does this mean?
I think it means, unfortunately, too many things for the word “device” to handle on its own.
Bits of hardware, software, versions, connectivity all blended into a muddle.
Upside-down, devil’s-advocate Lyza
                        asks self: All right, then, smarty pants,
                                 what do you suggest?



Monday, October 3, 11

Then I get frustrated with myself.
the web of now?



                                         the interblags?
                                                                             universal web?




                                            THE WEB
               pan-device web?



                                                                             The One Web?



                                 web 3.0?
                                                                                   Oh,whoops,the
             Ugh!Veto                                 future web?           W3Calready
                                                                                  nabbedthisterm
                                 web for all?



                                                             portable web?




Monday, October 3, 11

There are some nomenclature options. But none seem right, and none capture the essence of
what’s going on, that is, the web exploding out onto a galaxy of device-OS-browser-ugh-
whatever combinations. Bah! I’m sorry, George Orwell. Rest in peace. When you get down to
it, what we’re talking about is THE WEB. But then one loses track of the elements that set the
current and upcoming challenges of the web apart from the previous challenges of, shall we
say, the “traditional web.” Wrangling the emerging mobile or whatever web requires some
serious dev chops. So simply saying THE WEB doesn’t feel very satisfying either.
That was fruitless.
                • I’m going to say “device”
                • And I’m going to say “mobile web”
                • But keep in mind the underlying subtleties.




Monday, October 3, 11
For those who are saddling up and building the
                           mobile web, I applaud you.




Monday, October 3, 11

And now, as we embark, I want to give a shoutout to all of my other dev brothers and sisters.
This is a brave new world. I salute you.
Crap! It doesn’t
                 look quite right
                  Or: How I learned to stop worrying and set
                              my web sites free




Monday, October 3, 11
The situation today




                        photo by the internet




Monday, October 3, 11

Let’s start with some good news! The current situation with the web and the mobile web is a
bit of a recipe for FAIL. How’d this happen? Well, it started from the beginning.
In the 1990s, the Web was born, and boy, was it
                                     awesome.




Monday, October 3, 11

The beginning of the web, that is. We reached out to it, we embraced it because.
Monday, October 3, 11

Starry-eyed and enthusiastic, were so busy viewing source in Mosaic and learning how to
make transparent GIFs that we kind of neglected to grapple what we were up to. And we
kinda broke it a bit. That’s totally me in the 90s, wearing my college sweatshirt.
Striking out on a new medium, we had
                         a tendency to cling to the metaphors
                                   we already knew.




Monday, October 3, 11

It is perfectly natural to project the characteristics and constraints of a known medium onto
an emerging medium. Problem is, we never let go. What am I talking about here?
fixed-width layouts
                        spacer.gif




                                     We took (illusory) control.

                          tables for layout

                                                                 rigid columns




                               frames               font sizes




Monday, October 3, 11

To make the web do what we thought we wanted it to, and spurred by the needs and
demands of our customers, we grasped for control. Smart people had some clever ideas of
how to work around the constraints of the web to make it behave more like print media.
But...at what long-term cost?
“Please make the sentence fit all on one
                                                             line, like it does on the brochure.”




                         We acted like we had control, and our
                                customers believed us.

                        “Could you move the logo a half
                              pixel to the right?”




Monday, October 3, 11

Our customers believed that we had control. We sort of built monsters. We were selling pixel-
perfect control.
176x208

                                                           240x320



                                               640x480   320x480

                                     800x600


                          1024x768


                         1160x900




  2560x1600




Monday, October 3, 11

We approached the web as a series of slowly-increasing, static resolutions. We built rigid
windows into our content. We thought we saw a pattern. Screens are getting bigger, and
screen size is what defines our worlds. That’s what we told ourselves. Except. Oh! Mobile
came along! Then they started getting smaller again. Oh, wait! Internet televisions? bigger
again. This is breaking down!
We got away with this illusion of
                            control for awhile. But with the
                        explosion of mobile devices, browsers
                         and platforms, this forced control of
                         uncontrollable constraints is one of
                          the things that it is making it clear:




Monday, October 3, 11
We R DOIN IT
                                RONG.
                        Our false sense of control over layout combines
                          with other factors to make life for us on the
                         current pan-device web very di!cult indeed.



Monday, October 3, 11

At least, in some part, we’re doing it wrong. Not in all ways, but certain things we cling to are
hindering us in the quest for a better web.
Some other elements
                          of the dilemma
                        This is not my beautiful web. How did we get here?




Monday, October 3, 11

OK, I’ll relinquish my obsession with layout for just a moment. There’s other stuff going on
that is making the mobile web very hard. Let’s look at the building blocks of our failboat.
local storage
            web sockets               iOS Update breaks my video!
                                                                                             WebOS is dead. Long live WebOS


                        A new browser quirk              Device detection           Mobile transcoders



            Broken CSS selectors              HTML5                                    Geolocation on BlackBerry OS 4


                              No one can possibly “know enough”
      broken box model                                          Microformats
                                                                                                   Media Queries
                              CSS transforms on mobile

                                                         A new, slightly broken Android
           Responsive images
                                                                                                         cache manifest

                                                                        Feature detection
                People still use OpenWave?
                                                                                              different UI conventions
                                  Today’s newest JavaScript framework
                                                                                     Mango! IE9
                  HTML5 input types
                                                                    JavaScript performance
      DOM disasters                       Viewport tag



Monday, October 3, 11

It seems like today’s choices are either implement (and not keep up) or keep up (and never
have time to implement). Today’s mobile web expert really does need to be a rocket surgeon.
I would posit that it is not possible keep up fully, at all.
Legacy baggage




                        photo by Michael Coté




Monday, October 3, 11

We’re hobbled by legacy systems. Content Management Systems, those hefty tools we’ve
built over the years to allow “regular humans” to build and manage web content, are
completely wrong for the many-device web. Their templating scenarios are a nightmare.
Proprietary systems are even worse.
CMSes and WYSIWTF

                        Seeking to empower normal humans,
                         we built WYSIWYG editors that let
                        folks do everything from making text
                        purple to uploading 3MB images into a
                                 form eld. Whoops?




Monday, October 3, 11

How do you build content—and how do you teach your customers to build content—in a way
that allows for meaningful markup that actually works on various devices? Today’s so-called
WYSIWYG editors are hopelessly under-qualified for the task. Bad habits again catching up
with us.
We aren’t always using best practices*
                • Conflation of presentation and content
                • Bloated sites and resources that assume broadband-

                  level connections
                • Lack of basic accessibility and graceful degradation



                        * a.k.a. “Don’t have much time for getting this right,” “gotta ship,” “over
                                     budget,” “client doesn’t care,” and “laziness.”




Monday, October 3, 11

These things, while nice and important on the traditional web, are vital on the new web. To
get the job done on the previous-web (whatever we’re calling that), we built tools that are
now shooting us in the foot. We weren’t good enough about separating content from
presentation. WE got lazy. We have to be better.
We don’t get to make excuses, though.
                          As devs, we’re on the front lines,
                        expected to work around obscure and
                                     stupid stu#.




Monday, October 3, 11

Although these things are stacked up against us, We don’t get to make idealistic excuses for
why it’s broken. We have to ship.
Each new device, OS version, browser,
                                 browser version...




Monday, October 3, 11
Just serves to multiply the chaos.




Monday, October 3, 11
Monday, October 3, 11

Please, make it stop.
The current situation
                              feels un-
                                          Un-scalable.
                                          Un-testable.
                                        Un-surmountable.*

                 * Yes, I know how this word is supposed to look normally.




Monday, October 3, 11
Un-scalable.




Monday, October 3, 11
Experiment 1.




Monday, October 3, 11
10 very experienced mobile web professionals...




                        photo by lukew, modications by me




Monday, October 3, 11

A few weeks ago, I and 9 other people far smarter than myself secluded ourselves in the
Tennessee woods.
Isolated in a rural house...




                        photo by brad frost




Monday, October 3, 11

 We called this #mobilewood.
Working on a single project.




Monday, October 3, 11

Although we had an awful lot of fun, culminating in me falling into a bonfire at one point, we
worked our tushes off.
http://futurefriend.ly




Monday, October 3, 11

Building a manifesto, an idea, and a way of forging into the future. Trying to coalesce the gist
of what we sense is the right direction.
Dev




                                         Testing




                                         Iterating




Monday, October 3, 11

Madly, we built the site to express our ideas.
By the time we launched...




Monday, October 3, 11
Exhausted...




Monday, October 3, 11
Having debugged as much as possible...




Monday, October 3, 11
...about 100 hours’ time had been invested.




Monday, October 3, 11
Hmm. If you run the numbers...




Monday, October 3, 11
That’s about $15,000-20,000* at
                             average going rates.

                               *£10,000 - 13,000




Monday, October 3, 11
For three simple, static web pages.




Monday, October 3, 11

With a grand total of two images, no interactivity and all of the content is entirely static.
Experiment 1 working hypothesis:
                               This cannot scale.




Monday, October 3, 11

The barrier to entry for quality web development for the entire mobile web is too high.
Un-testable*.



            * To be clear, I’m not saying it’s 100% untestable. I’m saying it’s 100%
            impossible to test it 100%. Which makes it, in a sense, untestable.




Monday, October 3, 11

It feels very hard to test, this mobile web. Just thinking about testing makes me feel a bit
woozy.
So you think you can build a device
                                      library?




Monday, October 3, 11

So, what about building a device library to do your testing with?
Heck, we’re going to try




Monday, October 3, 11

Cloud Four helped to found Mobile Portland in 2008, which has become a rambunctiously
successful little organization and is now an official non-profit. Mobile Portland is currently
working with device and browser manufacturers and carriers to establish a mobile device
testing lab in our offices in downtown Portland.
But even so, there is no way we could
                          possibly have access even a small
                              percentage of all of the...




Monday, October 3, 11

This is a rather first-of-its-kind effort, and we are more than a little excited, but...
Devices

                            Platforms, OS Versions

                          Carriers and geographies

                                Mobile browsers




Monday, October 3, 11

Sigh. This massive fragmentation...
Monday, October 3, 11

What we’ll have will barely be a drop in the pond of all of the device combinations out there.
I didn’t do much math in college, but:




Monday, October 3, 11
The number of combinations is sort of mind-
                                   blowing*




               * I think that’s the technical term.


Monday, October 3, 11
“Our marketing manager has a
                        BlackBerry 8330 on Verizon. For him,
                        there is a weird border around all of
                            the links on the FAQ page.”
                                             —Pretty much every customer ever




Monday, October 3, 11

This is loosely based on typical real events. We’ve even had customers ship specific devices
to us and still been unable to reproduce client-reported bugs.
If I had a nickel for everything like
                                        that...




Monday, October 3, 11

Sure, we test the heck out of things, but if I had a nickel for every time I heard something
like...
I could probably
                retire young.




                                 photo by Volker Neumann




Monday, October 3, 11
Even a well-stocked device library is
                        never going to be able to represent the
                           full gamut of what’s out there.




Monday, October 3, 11

There are just too many combinations.
And there are only so many hours in
                                      the day.




Monday, October 3, 11

And just because you haven’t tested it doesn’t mean it’s not broken.
Un-surmountable.




Monday, October 3, 11

All this combines to make the mobile web feel unwinnable.
It can’t go on like this.*
                        * (But it likely will. For a while.)




Monday, October 3, 11
Monday, October 3, 11

The landscape feels pretty grim.
Well, that was
                         depressing.
                                 Now what?



Monday, October 3, 11

That was quite an onslaught of the bleak. Did I bring you here to make you swear off the web
forever?
Take heart.




Monday, October 3, 11
We can’t x everything right now, but by

    thinking in a future-friendly manner and
    relinquishing control we never had in the rst place,
    we can help shape the future of the web.




Monday, October 3, 11
Um, how?




Monday, October 3, 11
Things we can do right now.




Monday, October 3, 11
Deep breath. Release.




Monday, October 3, 11
Four considerations
                        and four weapons you
                        can use right now, in
                           the short term.

Monday, October 3, 11
Consideration 1: Start
                   to free your content.
                        “Content like water”




Monday, October 3, 11
Monday, October 3, 11

Like I keep harping on and on and on about, we’ve had a habit of keeping our
content in arbitrary cages, and we’re ignoring it at times, waylaid by the sound and
fury of other distractions. It wants out. We can help liberate it by retooling our
design practices.
Monday, October 3, 11

These new practices are some rst steps to treating our content like water.
Monday, October 3, 11

Opening the door to future greatness and content freedom.
Old and busted.




Monday, October 3, 11

The first mistake we often make when starting a new web site is to create a fixed-width,
blank canvas in photoshop and start cramming crap into it to fill the spaces. Oftentimes, we
ship off an approved mockup and never look back again. Implementation continues without
revisiting the design assumptions.
Monday, October 3, 11

Our tired, one-size-ts-a-few desktop web shoe doesn’t t the new generation.
New hotness.




Monday, October 3, 11

It’s time to get a bit smarter.
Monday, October 3, 11

Updating the design process: Its about flex, flow and adaptation. Showing a bit more, telling
a bit less.
Do this.
                        Instead of delivering static image-based
                        comps at one or more “resolutions,” consider
                        wireframes that demonstrate the !ow and !ex
                        of content across a continuum of device and
                        window sizes, indicating major breakpoints.




Monday, October 3, 11

Static, pixel-specific mockups lock in unrealistic expectations with clients about the way the
many-device web really works, and asserts that false control I keep whining about. Instead,
newer design techniques use proportional, simpler-feeling wireframes that show the site
adapting over a range of shapes, shifting flow more noticeably at defined breakpoints.
Image from “Pragmatic Responsive Design,”
              Stephanie Rieger




Monday, October 3, 11

This slide is from Stephanie Rieger’s great presentation about pragmatic responsive design,
which I’ll provide a link to at the end of this presentation, showing breakpoints in a design
her company, Yiibu, recently developed. Notice how the design adapts, and reflows to a
certain extent at each defined breakpoint. There is no pre-determined set of breakpoints.
They are per-project. Notice how the design scales between breakpoints, and then shifts
noticeably at the breakpoints.
Monday, October 3, 11

This kind of design gives your content the power to fill its own spaces, and is an element of
Responsive Web Design, which I’ll come back to in a few moments. Like vector versus raster
graphics, this design approach is about proportion and flexibility, not pixels and points.
Do this.
                        Build functional mockups—with
                        HTML where possible—so that
                        you can show (not tell).




Monday, October 3, 11

Stay away from rigid mockups that lock in expectations with clients. Get your customers
seeing the flow early and understanding the way that the design will adapt. Get yourself and
your customers handling the early prototype mockups on devices as soon as possible.
photo by Nick Thompson




Monday, October 3, 11

Retune to design iteratively. No longer can you deliver design stuff once to a client and never
look back.
Do this.
                        Work in tight, focused loops of
                        iterative design to deal with
                        inevitable, device-specic tweaks
                        and inevitable client feedback.




Monday, October 3, 11

Repetition and fine-tuning is inevitable in the state of the new web. Content informs design
and as things shift, your design will need to adapt.
Monday, October 3, 11

Granted, parts of this shift are a soft science, and hard for devs like me to glom onto easily.
However, the conversation does need to be steered over time and our customers enlightened.
Monday, October 3, 11

We need to help communicate where we’re putting our emphasis, and how flexible content
that is adaptive is really a good plan for the future. It won’t sell itself overnight, but let’s start
trying to talk about it. This is new stuff. We’re forging the future.
Monday, October 3, 11

Oh, dear, so while we’re talking about honoring content, what about that problem with user-
generated content and WYSIWYG editors and markup, oh, my!
Monday, October 3, 11

There are a couple of bridging techniques you could use while we work toward fixing the
content and CMS disaster. What I’m saying is: no one has fully solved this problem yet.
Do this.
                        Work with customers to build or
                        adapt existing APIs to access or
                        munge content.




Monday, October 3, 11

WYSIWYG doesn’t really exist. Until we can afford to retool all of the existing, mired legacy
systems out there, continue to fight the fight of separating content from presentation. On in-
depth projects, work with customers to build APIs to access content and data. You’d be
pleasantly surprised at how often APIs actually already exist, and how flexible customers’ dev
teams can be about building or extending them.
Do this.
                        Consider less presentation-
                        littered options like markdown or
                        textile for existing CMSes.




Monday, October 3, 11

But you can’t always build or use APIs. Another option is, for existing CMSes and less-than-
techy editorial customers, more minimal markup concepts like markdown or textile, which
keep presentation minimal in stored content, and also have the nice, future-friendly habit of
being human readable.
Consideration 2:
                            Essentials first!
                        Progressive enhancement isn’t just for the
                                  cool kids. It’s required.




Monday, October 3, 11

Many of you may have heard of the Mobile First mantra. My colleague Luke W. is a leading
proponent of this and has recently published an eponymous book. The idea of mobile first is
to, well, design for mobile first, and expand that design out to enhance for larger or more
powerful devices, e.g. the desktop.
Mobile rst!
                                 Essentials rst!




Monday, October 3, 11

 I think we’re onto something with this idea, hugely, but that maybe the word “mobile”, again,
is distracting us from what we’re really trying to accomplish. Maybe it’s more like essentials
or baseline first.
photo by seattle.roamer




Monday, October 3, 11

Either way, the point is, we got fat and lazy in many way and we need to start trying to pare
down our focus and get at what really matters in our web sites.
Monday, October 3, 11

This is a bigger-picture thought process about simplification and focus. A mobile- or
essentials-first attitude can help us go on a diet and figure out what really matters. It’s good
for us, and It’s not just about mobile.
Monday, October 3, 11

Finding serenity and meaning with your markup. Start from nothing. No JavaScript, no CSS.
Figure out what content, services and functionality matter for every user. By starting simple,
we avoid introducing (from the outset) complexity that will hinder our success, which is to
work on as many devices as possible.
Do this.
                        • Get laser-sharp focus on your markup. Start
                         with HTML. Believe in the HTML.

                        • Essentials rst. Focus on semantics, clarity
                         and simplicity. Is this the content that is
                         core to all of your users?




Monday, October 3, 11

Become extraordinarily friendly with the ins and outs of HTML5. This may seem like a no-
brainer, but I think one of the things we’ll see in the near future, as a result of the desperate
need for simplification, is some innovative approaches that build on rock-solid HTML5 and
probably some more frameworks that can do some of the annoying stuff that is so hard for
us.
Consideration 3: Now,
                  arm the weapons!
                 Adapt, enhance and optimize: a bunch of
                tools for your arsenal. Here come some slides
                              with text on them!



Monday, October 3, 11

We’ve got our future-friendly HTML5 and we’re ready to do something with it. There are
some tools out there to help simplify our lives and get our jobs done effectively. Some of
these tools and ideas are bridging techniques until the world gets to be a bit of a safer place.
Some are just great things.
Engage weapon 1: Adapt and !ex
                         with Responsive Web Design
                                   (RWD)




Monday, October 3, 11
Monday, October 3, 11

This is the article in A List Apart that introduced the idea of Responsive Web Design.
Brainchild of Ethan Marcotte, Responsive Web Design combines several implementation
techniques to bring to life the kind of flowing, adaptive layouts I’ve been talking about.
Monday, October 3, 11

Using a combination of CSS 3 media queries, fluid grids and fluid images and media, we can
build those flow-like-water layouts that adapt more easily across a lot of devices.
1: CSS 3 Media Queries


                @media all and (min-width: 480px) { }




Monday, October 3, 11

There are three technical underpinnings to the RWD approach. A quick CSS 3 Media query
primer for those who might not be initiated. CSS Media queries (one of the forty or so CSS 3
modules) let you selectively APPLY different CSS based on logical conditions. In this case, the
CSS rules between the brackets are applied only if the window width is greater or equal to
480px.
2: Fluid media.

                   img, object { max-width: 100%; }




Monday, October 3, 11

With this simple CSS rule comes great power. This makes our images and embedded objects
scale with the size of the containing element. Don’t forget that (at least not without great
futzing) you can’t use width and height tags on images and objects managed in this way.
This one really is this simple: just drop this rule into your CSS.
3: Fluid grids.
                •       CSS layouts based on proportional elements.

                •       Type in ems.

                •       Widths in percentages.

                •       Flexy, !exy!




Monday, October 3, 11

If you’re not doing fluid layouts now, you should be. Learning how to do it takes about half
an hour, and then you may find that your life is changed a bit for the shinier. Fluid grids use
percentages for body element widths and ems for type (typically). What does this mean? It
means that you’re not locking in any fixed units, and your design can scale. Fluid grids are a
riff on flexible grids, which have been around for a while. You can learn how to make them by
reading Ethan’s ALA article or his quick-read book.
Monday, October 3, 11

In this simple responsive design I threw together, you can see how three columns collapse
into one on a narrower screen. I’ve used a media query to apply different CSS based on
screen width. The layout is a fluid grid, with element widths defined with percentages.
Monday, October 3, 11

And also here, the use of fluid images allows the photo to scale with its container, fitting as
well into the single-column layout as the multi-column layout.
Monday, October 3, 11

Although there is a lot of hubbub about the specifics of RWD implementation (in fact, Cloud
Four co-founder Jason Grigsby wrote a controversial post about media queries that has
seriously made the rounds), try to let your mind float past the specifics about and meditate
on the premise, which has a certain harmony. Borrowed to some extent from ideals of
physical architecture, RWD is about flowing the content, adapting the environment around
the user instead of trying to control the experience rigidly or making the user adapt.
Do this.
                        Use media queries to enhance
                        layout. Avoid media queries in
                        your baseline, reference
                        implementation.




Monday, October 3, 11

Consider media queries as an enhancement technique. That way you’re not relying on
support in your baseline, content-is-king version. Hey, this is a great way of letting go of
some crap to worry about!
Do this.
                        You may need to use shims for IE.
                        But most desktop browsers are
                        media-query-savvy.




Monday, October 3, 11

You may need to use a JavaScript shim, if the media queries you’re making need to work in IE
7, 8 or whatever.
Do this.
                        Keep your eyes on your media and
                        image (!le) sizes! Take a peek at
                        Responsive Images (by Scott Jehl)
                        or server-side techniques.




Monday, October 3, 11

Just because you’re scaling images using the fluid technique doesn’t mean you’re out of the
woods. You’re still delivering all of the bytes that are in the full-sized image.
Do this.
                        We’ve found that it’s OK (and
                        relieves a bit of pressure) to leave
                        a bit of unmanaged gutter
                        (percentage) space in !uid
                        layouts.




Monday, October 3, 11

A lot of the tutorials out there for fluid grids have you accounting for every last scrape of
room in the design, often resulting in, literally, percentages with 6 or 7 decimal places. At
Cloud Four, we’ve found that we often avoid browser rounding difference issues and, really,
just painful math, by allowing for a floating percentage or two to creep into the space of the
design. Less precision-control, perhaps, but less likely to cause box-model rounding errors,
esp. in IE.
Target lock with weapon 2: Enhance
                        and adapt with client-side feature
                                     detection




Monday, October 3, 11
Monday, October 3, 11

With client-side feature detection, you can ask questions like, hey, do you support the HTML5
audio tag? I’d like to drop in some sound!
Monday, October 3, 11

These client-side feature detection tools ask the browser to tell us if it supports something
right at this very second. Then we can enhance our content based upon the answer.
Monday, October 3, 11

Modernizr is a prime contender in this space, and there are other cool polyfills, shims and
tools like yepnope.js, adapt.js...
Monday, October 3, 11

Sometimes it feels like there is a new JavaScript tool, library or framework every day. It can be
hard for me to keep my house in order! But the up side is that there are tons of things to help
you get your job done out there.
Do this.
                        Keep it e$cient. Use Modernizr’s
                        new-ish modular approach to
                        build your feature detection.




Monday, October 3, 11

Don’t throw in the kitchen sink! This keeps your JavaScript payload size small and demands
less of your user’s browsers and CPUs.
Know this.
                        Client-side feature detection
                        works most of the time. But it is not
                        infallible (have you noticed that
                        nothing is?).




Monday, October 3, 11
Weapon 3: Rocking it old skool on
                                 the server side




Monday, October 3, 11
Monday, October 3, 11

You can do some heavy-lifting on the server side, some gearwork so that you’re not putting
so much pressure on lighter clients.
Server-side devs #represent
                •       There are absolutely valid reasons that you might
                        want to alter markup before you serve it to clients.
                        Here are some words that start with “Re-.”

                        •   Reordering

                        •   Reduction

                        •   Respect




Monday, October 3, 11
User Agent Sni$ng




                photo by ex.libris




Monday, October 3, 11

Sometimes user-agent sniffing gets a bum rap, but I’m done apologizing. In our wild world,
there is often not another viable tool. Making our best estimates about an incoming device is
not something only small-time folks do; most major websites that have mobile optimization
are using device detection of some sort, and the vast majority of those hinge on user agent
strings. It ain’t perfect, but it works.
Device Databases




                photo by Tim Morgan




Monday, October 3, 11

So, given a user agent string, how do we know more information about the client? That’s the
job of device databases, which look up various capabilities based on, well, usually, a user
agent string. We can make good first estimates about the resolution, browser version, video
support, etc.
Monday, October 3, 11

You gotta crack some eggs sometimes to make that tasty omelette. This isn’t about locking
people out or dumbing down their content or locking them in to a particular view of content.
There’s some nuance that can be used here.
Do Don’t this.
                        • Don’t be afraid to do some server-side optimization.
                          Don’t let the bastards get you down.

                        • Don’t overdo it.
                        • Don’t leave folks out in the cold (without an escape
                          mechanism).




Monday, October 3, 11

Don’t this. And by combining server-side detection with clients-side detection, you can find
considerably more nuance.
Monday, October 3, 11

There’s also a bit of Zen in the combination of weapons 2 and 3, that is, using a server-side
approach to make an educated first stab, and augmenting or correcting this guess with live,
client-side feature detection. Bryan Rieger at Yiibu has done some very good work in this
area...
Killer Weapon #4: Optimize the
                                 hell out of it




Monday, October 3, 11
Do this.
                        Huge, huge improvements can often be made
                        in a couple of minutes by editing
                        your .htaccess or apache conguration le.




Monday, October 3, 11

You don’t get a get-out-of-jail-free card on this one. Performance on mobile matters more
than ever. It’s amazing the massive performance improvements that can be made that are
routinely overlooked by devs. These are simple changes that have huge impact.
Monday, October 3, 11
Do this.
                        Get the YSlow extension for
                        Firebug in your browser. Read it,
                        study it, know it.




Monday, October 3, 11
GZip. Don’t even really consider not doing it.
                # Add gzip compression
                IfModule mod_deflate.c
                  AddOutputFilterByType DEFLATE    text/html
                  AddOutputFilterByType DEFLATE    text/plain
                  AddOutputFilterByType DEFLATE    text/xml
                  AddOutputFilterByType DEFLATE    text/css
                  AddOutputFilterByType DEFLATE    application/javascript
                  AddOutputFilterByType DEFLATE    application/x-javascript
                  AddOutputFilterByType DEFLATE    application/x-httpd-php
                  AddOutputFilterByType DEFLATE    application/rss+xml
                  AddOutputFilterByType DEFLATE    application/atom_xml
                /IfModule




Monday, October 3, 11

I’m giving you some basically cut-and-pastable code for an .htaccess file so you can’t use the
excuse that you don’t know how. This madly, madly cuts payloads.
Far-future expires headers
                IfModule mod_expires.c
                  # Enable expirations.
                  ExpiresActive On
                  # Cache all files for 2 weeks after access (A).
                  ExpiresDefault A1209600
                /IfModule




Monday, October 3, 11

Tell browsers not to refresh content for a while; keep it cached. Be aware that when you’re
turning this on, you’re kind of locking yourself into the file version. You’ll have to invent a
file-naming convention to work around this.
cache manifests

                    AddType text/cache-manifest .appcache




Monday, October 3, 11

I won’t lie. Futzing with cache manifests is a bit of a finicky business. You may need this in
your apache config/.htaccess to make them work.
cache manifests
                CACHE MANIFEST

                CACHE:

                /assets/fflogo.png
                /assets/signed.png

                /index.html
                /thinking.html
                /resources.html

                /styles.css

                NETWORK:
                *




Monday, October 3, 11

Here’s the contents of the cache manifest on futurefriendly.
IV. Now find places to
                      draw the line.
                        Letting go and finding a bit of balance.




Monday, October 3, 11
Plant the seed early.




Monday, October 3, 11

Plant the seed early. As much as I loathe the expression: “Set expectations.” Learn to talk
about what devices can and cannot do, how browsers break, and how you can’t control
everything.
Take note of when you get mired.




Monday, October 3, 11

Sometimes when you’re deeply in dev, you can’t see the forest for the trees. Learn to
recognize when you’re mired. Take note. Try not to chase your tail quite as much.
Don’t fear the occasional egregious hack.




Monday, October 3, 11

Don’t be afraid to pull out an egregious hack or two. Use your best duct tape programming
skills, as per Joel Spolsky.
Put your energy into the devices that “matter.”




Monday, October 3, 11

Focus on the devices that matter. That doesn’t mean to do this at the expense of everyone
else, but don’t get mired in small tweaks for every single thing out there.
Fail with grace.




Monday, October 3, 11

Be ready to fail gracefully a bit when you set your site free. You have the good underpinnings
there to fall back on.
And what about the future?
                  Looking further ahead.




Monday, October 3, 11
Disruption will only accelerate. The quantity and diversity of
                        connected devices—many of which we haven't imagined yet—will
                        explode, as will the quantity and diversity of the people around the
                        world who use them. Our existing standards, workflows, and
                        infrastructure won't hold up. Today's onslaught of devices is already
                        pushing them to the breaking point. They can't withstand what's
                        ahead. Proprietary solutions will dominate at first. Innovation
                        necessarily precedes standardization. Technologists will scramble to
                        these solutions before realizing (yet again) that a standardized
                        platform is needed to maintain sanity. The standards process will be
                        painfully slow. We will struggle with (and eventually agree upon)
                        appropriate standards. During this period, the web will fall even
                        further behind proprietary solutions.


                                                          http://futurefriend.ly



Monday, October 3, 11
Emancipating mobile browsers from
                                   the ghetto.




Monday, October 3, 11

What does this mean? For one thing it means changing the conversation that has...
Changing the conversation.




Monday, October 3, 11

Changing the conversation? Yes, right now the tone is slightly odd. As devs, we consider it
our responsibility to deal with the myriad, weird, specific, quirky device and browser bugs.
We should try to slowly turn this conversation back around and make the onus on device and
OS and browser makers—the people who actually have control over this—make things work
as advertised, and deliver on promises.
Be future friendly.




Monday, October 3, 11

Some of the considerations I talked about run parallel to the future friendly ideals. We’re still
ironing out the kinks.
We can steer this ship.




Monday, October 3, 11

We’re not totally sure exactly what the future looks like. But by thinking in a future-friendly
manner, you can help get the ship on track.
Victory can be ours.




Monday, October 3, 11

I believe that, though the ride will be bumpy for a while, the increasing chaos will eventually
reach a tipping point—at least I hope so.
Remember, this isn’t religion.




Monday, October 3, 11

And we’re all on the same team. Don’t let yourself get caught up in over-idealized squabbles.
Let’s work together.
Monday, October 3, 11

Set it freeeeeee!
Must-Reads
                • All of the resources on http://futurefriend.ly/resources.html
                • “Pragmatic Responsive Design” Stephanie Rieger http://
                  www.slideshare.net/yiibu/pragmatic-responsive-design
                • Responsive Web Design, Ethan Marcotte http://www.abookapart.com/
                  products/responsive-web-design
                • Mobile First, Luke Wroblewski, http://www.abookapart.com/
                  products/mobile-first
                • “Meta Layout: A Closer Look at Media Queries”, Stephen Hay
                  http://www.slideshare.net/stephenhay/mobilism2011
                • “Rethinking the Mobile Web” Bryan Rieger http://
                  www.slideshare.net/bryanrieger/rethinking-the-mobile-web-by-
                  yiibu
                • “The Duct Tape Programmer” Joel Spolsky http://
                  www.joelonsoftware.com/items/2009/09/23.html



Monday, October 3, 11
Coming soon.




Monday, October 3, 11
Thanks for enduring me!
                Lyza Danger Gardner
                lyza@lyza.com
                @lyzadanger

                         Photos ‘n stu# in this
                        presentation are mine
                        unless otherwise noted
                                                  Youcanuse‘em
                                                   too(Creative
                                                     Commons)
Monday, October 3, 11

Weitere ähnliche Inhalte

Ähnlich wie Crap! It doesn't look quite right, or, how I learned to stop worrying and set my mobile web sites free

Gavin Bell Toc09 Long Tail Needs Community Sm
Gavin Bell Toc09 Long Tail Needs Community SmGavin Bell Toc09 Long Tail Needs Community Sm
Gavin Bell Toc09 Long Tail Needs Community SmGavin Bell
 
Open Source in the Cloud Computing Era
Open Source in the Cloud Computing EraOpen Source in the Cloud Computing Era
Open Source in the Cloud Computing EraTim O'Reilly
 
The Future is Responsive
The Future is ResponsiveThe Future is Responsive
The Future is ResponsiveJonathan Smiley
 
Digital - from websites to ecosystems
Digital - from websites to ecosystemsDigital - from websites to ecosystems
Digital - from websites to ecosystemsMikael Nemeschansky
 
The New Internet: When Everything Becomes Smart
The New Internet: When Everything Becomes SmartThe New Internet: When Everything Becomes Smart
The New Internet: When Everything Becomes SmartJeeni
 
The Agony and Ecstasy of the Mobile Web
The Agony and Ecstasy of the Mobile WebThe Agony and Ecstasy of the Mobile Web
The Agony and Ecstasy of the Mobile Webgreenideas
 
Horn Creek Leadership Retreat
Horn Creek Leadership RetreatHorn Creek Leadership Retreat
Horn Creek Leadership RetreatGomindSHIFT
 
Internet primer or Internet for Dummies (for Filipino women)
Internet primer or Internet for Dummies (for Filipino women)Internet primer or Internet for Dummies (for Filipino women)
Internet primer or Internet for Dummies (for Filipino women)Eric Clark Su
 
Mobile Accessibility - Accessibility Camp Toronto
Mobile Accessibility - Accessibility Camp TorontoMobile Accessibility - Accessibility Camp Toronto
Mobile Accessibility - Accessibility Camp TorontoTed Drake
 
Presentacion informacion sobre el internet
Presentacion informacion sobre el internetPresentacion informacion sobre el internet
Presentacion informacion sobre el internetverohamed
 
Los Angeles R users group - Nov 17 2010 - Part 2
Los Angeles R users group - Nov 17 2010 - Part 2Los Angeles R users group - Nov 17 2010 - Part 2
Los Angeles R users group - Nov 17 2010 - Part 2rusersla
 
From Apples to Augmented Cognition (Current and Future Trends in Mobile)
From Apples to Augmented Cognition (Current and Future Trends in Mobile)From Apples to Augmented Cognition (Current and Future Trends in Mobile)
From Apples to Augmented Cognition (Current and Future Trends in Mobile)Paul Golding
 
Coding on the Shoulders of Giants
Coding on the Shoulders of GiantsCoding on the Shoulders of Giants
Coding on the Shoulders of GiantsMatt Biddulph
 
The ‘Third Space’ in the cloud
The ‘Third Space’ in the cloudThe ‘Third Space’ in the cloud
The ‘Third Space’ in the cloudSherry Jones
 
Popular Creative Essay Editor Site For School
Popular Creative Essay Editor Site For SchoolPopular Creative Essay Editor Site For School
Popular Creative Essay Editor Site For SchoolLaura Lewis
 
Roelof Temmingh FIRST07 slides
Roelof Temmingh FIRST07 slidesRoelof Temmingh FIRST07 slides
Roelof Temmingh FIRST07 slidesLeon Kuunders
 
VU University Amsterdam: Web & Media Group MSc Projects
VU University Amsterdam: Web & Media Group MSc ProjectsVU University Amsterdam: Web & Media Group MSc Projects
VU University Amsterdam: Web & Media Group MSc ProjectsLora Aroyo
 
Developing a Progressive Mobile Strategy (Key Comm Version)
Developing a Progressive Mobile Strategy (Key Comm Version)Developing a Progressive Mobile Strategy (Key Comm Version)
Developing a Progressive Mobile Strategy (Key Comm Version)Dave Olsen
 

Ähnlich wie Crap! It doesn't look quite right, or, how I learned to stop worrying and set my mobile web sites free (20)

Gavin Bell Toc09 Long Tail Needs Community Sm
Gavin Bell Toc09 Long Tail Needs Community SmGavin Bell Toc09 Long Tail Needs Community Sm
Gavin Bell Toc09 Long Tail Needs Community Sm
 
Open Source in the Cloud Computing Era
Open Source in the Cloud Computing EraOpen Source in the Cloud Computing Era
Open Source in the Cloud Computing Era
 
The Future is Responsive
The Future is ResponsiveThe Future is Responsive
The Future is Responsive
 
My dotJS Talk
My dotJS TalkMy dotJS Talk
My dotJS Talk
 
Digital - from websites to ecosystems
Digital - from websites to ecosystemsDigital - from websites to ecosystems
Digital - from websites to ecosystems
 
The New Internet: When Everything Becomes Smart
The New Internet: When Everything Becomes SmartThe New Internet: When Everything Becomes Smart
The New Internet: When Everything Becomes Smart
 
The Agony and Ecstasy of the Mobile Web
The Agony and Ecstasy of the Mobile WebThe Agony and Ecstasy of the Mobile Web
The Agony and Ecstasy of the Mobile Web
 
Horn Creek Leadership Retreat
Horn Creek Leadership RetreatHorn Creek Leadership Retreat
Horn Creek Leadership Retreat
 
Internet primer or Internet for Dummies (for Filipino women)
Internet primer or Internet for Dummies (for Filipino women)Internet primer or Internet for Dummies (for Filipino women)
Internet primer or Internet for Dummies (for Filipino women)
 
Mobile Accessibility - Accessibility Camp Toronto
Mobile Accessibility - Accessibility Camp TorontoMobile Accessibility - Accessibility Camp Toronto
Mobile Accessibility - Accessibility Camp Toronto
 
Presentacion informacion sobre el internet
Presentacion informacion sobre el internetPresentacion informacion sobre el internet
Presentacion informacion sobre el internet
 
Los Angeles R users group - Nov 17 2010 - Part 2
Los Angeles R users group - Nov 17 2010 - Part 2Los Angeles R users group - Nov 17 2010 - Part 2
Los Angeles R users group - Nov 17 2010 - Part 2
 
From Apples to Augmented Cognition (Current and Future Trends in Mobile)
From Apples to Augmented Cognition (Current and Future Trends in Mobile)From Apples to Augmented Cognition (Current and Future Trends in Mobile)
From Apples to Augmented Cognition (Current and Future Trends in Mobile)
 
Coding on the Shoulders of Giants
Coding on the Shoulders of GiantsCoding on the Shoulders of Giants
Coding on the Shoulders of Giants
 
Future of semantic apps
Future of semantic appsFuture of semantic apps
Future of semantic apps
 
The ‘Third Space’ in the cloud
The ‘Third Space’ in the cloudThe ‘Third Space’ in the cloud
The ‘Third Space’ in the cloud
 
Popular Creative Essay Editor Site For School
Popular Creative Essay Editor Site For SchoolPopular Creative Essay Editor Site For School
Popular Creative Essay Editor Site For School
 
Roelof Temmingh FIRST07 slides
Roelof Temmingh FIRST07 slidesRoelof Temmingh FIRST07 slides
Roelof Temmingh FIRST07 slides
 
VU University Amsterdam: Web & Media Group MSc Projects
VU University Amsterdam: Web & Media Group MSc ProjectsVU University Amsterdam: Web & Media Group MSc Projects
VU University Amsterdam: Web & Media Group MSc Projects
 
Developing a Progressive Mobile Strategy (Key Comm Version)
Developing a Progressive Mobile Strategy (Key Comm Version)Developing a Progressive Mobile Strategy (Key Comm Version)
Developing a Progressive Mobile Strategy (Key Comm Version)
 

Kürzlich hochgeladen

Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfPrecisely
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupFlorian Wilhelm
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clashcharlottematthew16
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionDilum Bandara
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningLars Bell
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsPixlogix Infotech
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubKalema Edgar
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piececharlottematthew16
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfRankYa
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...Fwdays
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024BookNet Canada
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteDianaGray10
 

Kürzlich hochgeladen (20)

Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdfHyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
Hyperautomation and AI/ML: A Strategy for Digital Transformation Success.pdf
 
Streamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project SetupStreamlining Python Development: A Guide to a Modern Project Setup
Streamlining Python Development: A Guide to a Modern Project Setup
 
Powerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time ClashPowerpoint exploring the locations used in television show Time Clash
Powerpoint exploring the locations used in television show Time Clash
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
Advanced Computer Architecture – An Introduction
Advanced Computer Architecture – An IntroductionAdvanced Computer Architecture – An Introduction
Advanced Computer Architecture – An Introduction
 
DSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine TuningDSPy a system for AI to Write Prompts and Do Fine Tuning
DSPy a system for AI to Write Prompts and Do Fine Tuning
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
The Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and ConsThe Ultimate Guide to Choosing WordPress Pros and Cons
The Ultimate Guide to Choosing WordPress Pros and Cons
 
Unleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding ClubUnleash Your Potential - Namagunga Girls Coding Club
Unleash Your Potential - Namagunga Girls Coding Club
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Story boards and shot lists for my a level piece
Story boards and shot lists for my a level pieceStory boards and shot lists for my a level piece
Story boards and shot lists for my a level piece
 
Search Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdfSearch Engine Optimization SEO PDF for 2024.pdf
Search Engine Optimization SEO PDF for 2024.pdf
 
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks..."LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
"LLMs for Python Engineers: Advanced Data Analysis and Semantic Kernel",Oleks...
 
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
New from BookNet Canada for 2024: BNC CataList - Tech Forum 2024
 
Take control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test SuiteTake control of your SAP testing with UiPath Test Suite
Take control of your SAP testing with UiPath Test Suite
 

Crap! It doesn't look quite right, or, how I learned to stop worrying and set my mobile web sites free

  • 1. Crap! It doesn’t look quite right Or: How I learned to stop worrying and set my web sites free Lyza Danger Gardner / lyza@lyza.com @lyzadanger / Over the Air, 2011 Monday, October 3, 11
  • 2. Hi, there, Bletchley Park. My name is Lyza. Monday, October 3, 11
  • 3. I love the web. photo by lukew Monday, October 3, 11 Hi, I’m Lyza. I love the web. I always have. Ever since the 1990s, when the web was just a wee baby.
  • 4. I hail from Portland. Hi! Monday, October 3, 11 I live in Portland, Oregon, USA. In fact, I was born and raised there. This is actually seriously unusual. Portland is the kind of place people want to move to, and increasingly, it’s hard to find actual natives.
  • 5. Monday, October 3, 11 In Portland, we are known for our coffee.
  • 6. Monday, October 3, 11 Our beer...
  • 7. Monday, October 3, 11 ...and our foodie inclinations.
  • 8. Portland is also famous for its hipsters, bikes and other stu! I don’t have photos of. Come visit. It’s fun. Monday, October 3, 11 And a host of other trendy things. Portland’s grown a reputation of late and is particularly the darling of the New York Times, which publishes fawning articles about its quaintness regularly. As you can tell, I’m proud of the town. And it also has a strong mobile development community.
  • 9. Portland + Interwebs + mobile + Iamonateam withsome wickedlysmart } Dramatis personae people = Cloud Four Monday, October 3, 11 So, I live in Portland, and in 2007 I helped co-found Cloud Four with three other folks I’ve worked with for over a decade. We came from a deep “traditional” web background and we wanted to seize on the incredibly neat opportunities provided by mobile.
  • 10. Cloud Four chose the web. It was in no way an easy choice. Monday, October 3, 11
  • 11. 2008 Flashbackto Monday, October 3, 11 We founded Cloud Four in 2007, with an initial vision of mobile web goodness. In 2008, a lot of stuff happened.
  • 12. As luck would have it... I was fortunate enough to be on the team that developed the Obama iPhone app. Monday, October 3, 11
  • 13. What an exciting time. This was a mere few months after the initial launch of the App Store. Everyone was very excited. Monday, October 3, 11 This was in the late summer of 2008, mere months after the initial launch of Apple’s App Store in the US. Everyone was basically quivering with excitement.
  • 14. Now what? Follow the !ow and build native apps for a living, or continue to bank on the promise of the web? photo by Robert Goodwin Monday, October 3, 11 At Cloud Four, we were faced with a crossroads. Colleagues we knew and admired were throwing in their lot with native iOS apps. Should we stick with our original dream, pinning our hopes on what we see as a more democratic, more universal and more meaningful technology?
  • 15. What apps can do, the web can do, too... Monday, October 3, 11 Cloud Four co-founder Jason Grigsby went over the features of the Obama application with a fine-toothed comb. His realization here? There’s nothing in this app that couldn’t be accomplished with web technologies.
  • 16. Since then, at Cloud Four... Monday, October 3, 11 Epiphanies like this helped us make up our minds. We stuck with the web. Since then, we’ve built stuff.
  • 17. High-performance mobile web applications and sites. Monday, October 3, 11 Like Hautelook.com’s mobile site. Hautelook is a fashion flash-sale site with extreme traffic spikes as, at 8am each morning, frantic fashion-conscious bargain-seeking shoppers descend on the site. It is one of the top 2k sites in the world, and boy, howdy are shoppers going to be mad if they can’t access the site because of performance problems or rendering issues.
  • 18. Web sites and applications for both “desktop” and “mobile” devices and browsers. Monday, October 3, 11 But it’s not all about standalone mobile sites—in fact, we generally aim for the opposite. For example, we build this full-gamut site for a local craft brewery in Oregon. There’s some neat stuff going on here that you couldn’t do before mobile, for example, we use geolocation to help users find the closest shop, bar, or restaurant that carries a specific brew that Deschutes makes. Fun stuff! We love the mobile web.
  • 19. The mobile web is hard. Monday, October 3, 11 We’ve learned something. The mobile web is hard. And, frankly, instead of easing up as time goes by, it kind of seems to be getting harder right now. Before we get down to our little chat here, I want to take a moment to make annoying observations about linguistics.
  • 20. (A brief aside) regarding terminology. Monday, October 3, 11 Before we get down to our little chat here, I want to take a moment to make annoying observations about linguistics.
  • 21. “There is no mobile web.” —Jeremy Keith (@ada!io) Monday, October 3, 11 Well-known web dude Jeremy Keith gave a presentation a few weeks ago at the Breaking Development Conference in Nashville, Tenn. The title of his presentation was “There is no mobile web.” At the time, I thought he was trying to stir up a bit of controversy.
  • 22. At rst, I didn’t get it. Monday, October 3, 11 Surely, this is splitting semantic hairs? But then I thought about it a bit more.
  • 23. The stu# we’re up against is bigger than a pile telephones photo by Dave Patten Monday, October 3, 11 Not everything that browses the web is a desktop computer or a telephone. By referring to the “mobile web,” we’re both ignoring the broader context and acting like there is more than one web, when in fact the goal is universality.
  • 24. So many devices. Monday, October 3, 11 It’s about making the web fit a vast array of devices and platforms. Everyone loves mentioning those still-odd outliers like Automobiles. Refrigerators. Wristwatches. Yes, mobile devices like phones represent the big thrust, but the meaning is deeper.
  • 25. also... Monday, October 3, 11 Just to make things yet more complex...
  • 26. What do we mean when we say “device?” device itself (hardware) + Chancesare,we platform meanbitsand + botsofvarious OS things + browser + carrier/connectivity elements Monday, October 3, 11 We talk about the devices that are accessing our services. In web terms, what does this mean? I think it means, unfortunately, too many things for the word “device” to handle on its own. Bits of hardware, software, versions, connectivity all blended into a muddle.
  • 27. Upside-down, devil’s-advocate Lyza asks self: All right, then, smarty pants, what do you suggest? Monday, October 3, 11 Then I get frustrated with myself.
  • 28. the web of now? the interblags? universal web? THE WEB pan-device web? The One Web? web 3.0? Oh,whoops,the Ugh!Veto future web? W3Calready nabbedthisterm web for all? portable web? Monday, October 3, 11 There are some nomenclature options. But none seem right, and none capture the essence of what’s going on, that is, the web exploding out onto a galaxy of device-OS-browser-ugh- whatever combinations. Bah! I’m sorry, George Orwell. Rest in peace. When you get down to it, what we’re talking about is THE WEB. But then one loses track of the elements that set the current and upcoming challenges of the web apart from the previous challenges of, shall we say, the “traditional web.” Wrangling the emerging mobile or whatever web requires some serious dev chops. So simply saying THE WEB doesn’t feel very satisfying either.
  • 29. That was fruitless. • I’m going to say “device” • And I’m going to say “mobile web” • But keep in mind the underlying subtleties. Monday, October 3, 11
  • 30. For those who are saddling up and building the mobile web, I applaud you. Monday, October 3, 11 And now, as we embark, I want to give a shoutout to all of my other dev brothers and sisters. This is a brave new world. I salute you.
  • 31. Crap! It doesn’t look quite right Or: How I learned to stop worrying and set my web sites free Monday, October 3, 11
  • 32. The situation today photo by the internet Monday, October 3, 11 Let’s start with some good news! The current situation with the web and the mobile web is a bit of a recipe for FAIL. How’d this happen? Well, it started from the beginning.
  • 33. In the 1990s, the Web was born, and boy, was it awesome. Monday, October 3, 11 The beginning of the web, that is. We reached out to it, we embraced it because.
  • 34. Monday, October 3, 11 Starry-eyed and enthusiastic, were so busy viewing source in Mosaic and learning how to make transparent GIFs that we kind of neglected to grapple what we were up to. And we kinda broke it a bit. That’s totally me in the 90s, wearing my college sweatshirt.
  • 35. Striking out on a new medium, we had a tendency to cling to the metaphors we already knew. Monday, October 3, 11 It is perfectly natural to project the characteristics and constraints of a known medium onto an emerging medium. Problem is, we never let go. What am I talking about here?
  • 36. fixed-width layouts spacer.gif We took (illusory) control. tables for layout rigid columns frames font sizes Monday, October 3, 11 To make the web do what we thought we wanted it to, and spurred by the needs and demands of our customers, we grasped for control. Smart people had some clever ideas of how to work around the constraints of the web to make it behave more like print media. But...at what long-term cost?
  • 37. “Please make the sentence fit all on one line, like it does on the brochure.” We acted like we had control, and our customers believed us. “Could you move the logo a half pixel to the right?” Monday, October 3, 11 Our customers believed that we had control. We sort of built monsters. We were selling pixel- perfect control.
  • 38. 176x208 240x320 640x480 320x480 800x600 1024x768 1160x900 2560x1600 Monday, October 3, 11 We approached the web as a series of slowly-increasing, static resolutions. We built rigid windows into our content. We thought we saw a pattern. Screens are getting bigger, and screen size is what defines our worlds. That’s what we told ourselves. Except. Oh! Mobile came along! Then they started getting smaller again. Oh, wait! Internet televisions? bigger again. This is breaking down!
  • 39. We got away with this illusion of control for awhile. But with the explosion of mobile devices, browsers and platforms, this forced control of uncontrollable constraints is one of the things that it is making it clear: Monday, October 3, 11
  • 40. We R DOIN IT RONG. Our false sense of control over layout combines with other factors to make life for us on the current pan-device web very di!cult indeed. Monday, October 3, 11 At least, in some part, we’re doing it wrong. Not in all ways, but certain things we cling to are hindering us in the quest for a better web.
  • 41. Some other elements of the dilemma This is not my beautiful web. How did we get here? Monday, October 3, 11 OK, I’ll relinquish my obsession with layout for just a moment. There’s other stuff going on that is making the mobile web very hard. Let’s look at the building blocks of our failboat.
  • 42. local storage web sockets iOS Update breaks my video! WebOS is dead. Long live WebOS A new browser quirk Device detection Mobile transcoders Broken CSS selectors HTML5 Geolocation on BlackBerry OS 4 No one can possibly “know enough” broken box model Microformats Media Queries CSS transforms on mobile A new, slightly broken Android Responsive images cache manifest Feature detection People still use OpenWave? different UI conventions Today’s newest JavaScript framework Mango! IE9 HTML5 input types JavaScript performance DOM disasters Viewport tag Monday, October 3, 11 It seems like today’s choices are either implement (and not keep up) or keep up (and never have time to implement). Today’s mobile web expert really does need to be a rocket surgeon. I would posit that it is not possible keep up fully, at all.
  • 43. Legacy baggage photo by Michael Coté Monday, October 3, 11 We’re hobbled by legacy systems. Content Management Systems, those hefty tools we’ve built over the years to allow “regular humans” to build and manage web content, are completely wrong for the many-device web. Their templating scenarios are a nightmare. Proprietary systems are even worse.
  • 44. CMSes and WYSIWTF Seeking to empower normal humans, we built WYSIWYG editors that let folks do everything from making text purple to uploading 3MB images into a form eld. Whoops? Monday, October 3, 11 How do you build content—and how do you teach your customers to build content—in a way that allows for meaningful markup that actually works on various devices? Today’s so-called WYSIWYG editors are hopelessly under-qualified for the task. Bad habits again catching up with us.
  • 45. We aren’t always using best practices* • Conflation of presentation and content • Bloated sites and resources that assume broadband- level connections • Lack of basic accessibility and graceful degradation * a.k.a. “Don’t have much time for getting this right,” “gotta ship,” “over budget,” “client doesn’t care,” and “laziness.” Monday, October 3, 11 These things, while nice and important on the traditional web, are vital on the new web. To get the job done on the previous-web (whatever we’re calling that), we built tools that are now shooting us in the foot. We weren’t good enough about separating content from presentation. WE got lazy. We have to be better.
  • 46. We don’t get to make excuses, though. As devs, we’re on the front lines, expected to work around obscure and stupid stu#. Monday, October 3, 11 Although these things are stacked up against us, We don’t get to make idealistic excuses for why it’s broken. We have to ship.
  • 47. Each new device, OS version, browser, browser version... Monday, October 3, 11
  • 48. Just serves to multiply the chaos. Monday, October 3, 11
  • 49. Monday, October 3, 11 Please, make it stop.
  • 50. The current situation feels un- Un-scalable. Un-testable. Un-surmountable.* * Yes, I know how this word is supposed to look normally. Monday, October 3, 11
  • 53. 10 very experienced mobile web professionals... photo by lukew, modications by me Monday, October 3, 11 A few weeks ago, I and 9 other people far smarter than myself secluded ourselves in the Tennessee woods.
  • 54. Isolated in a rural house... photo by brad frost Monday, October 3, 11 We called this #mobilewood.
  • 55. Working on a single project. Monday, October 3, 11 Although we had an awful lot of fun, culminating in me falling into a bonfire at one point, we worked our tushes off.
  • 56. http://futurefriend.ly Monday, October 3, 11 Building a manifesto, an idea, and a way of forging into the future. Trying to coalesce the gist of what we sense is the right direction.
  • 57. Dev Testing Iterating Monday, October 3, 11 Madly, we built the site to express our ideas.
  • 58. By the time we launched... Monday, October 3, 11
  • 60. Having debugged as much as possible... Monday, October 3, 11
  • 61. ...about 100 hours’ time had been invested. Monday, October 3, 11
  • 62. Hmm. If you run the numbers... Monday, October 3, 11
  • 63. That’s about $15,000-20,000* at average going rates. *£10,000 - 13,000 Monday, October 3, 11
  • 64. For three simple, static web pages. Monday, October 3, 11 With a grand total of two images, no interactivity and all of the content is entirely static.
  • 65. Experiment 1 working hypothesis: This cannot scale. Monday, October 3, 11 The barrier to entry for quality web development for the entire mobile web is too high.
  • 66. Un-testable*. * To be clear, I’m not saying it’s 100% untestable. I’m saying it’s 100% impossible to test it 100%. Which makes it, in a sense, untestable. Monday, October 3, 11 It feels very hard to test, this mobile web. Just thinking about testing makes me feel a bit woozy.
  • 67. So you think you can build a device library? Monday, October 3, 11 So, what about building a device library to do your testing with?
  • 68. Heck, we’re going to try Monday, October 3, 11 Cloud Four helped to found Mobile Portland in 2008, which has become a rambunctiously successful little organization and is now an official non-profit. Mobile Portland is currently working with device and browser manufacturers and carriers to establish a mobile device testing lab in our offices in downtown Portland.
  • 69. But even so, there is no way we could possibly have access even a small percentage of all of the... Monday, October 3, 11 This is a rather first-of-its-kind effort, and we are more than a little excited, but...
  • 70. Devices Platforms, OS Versions Carriers and geographies Mobile browsers Monday, October 3, 11 Sigh. This massive fragmentation...
  • 71. Monday, October 3, 11 What we’ll have will barely be a drop in the pond of all of the device combinations out there.
  • 72. I didn’t do much math in college, but: Monday, October 3, 11
  • 73. The number of combinations is sort of mind- blowing* * I think that’s the technical term. Monday, October 3, 11
  • 74. “Our marketing manager has a BlackBerry 8330 on Verizon. For him, there is a weird border around all of the links on the FAQ page.” —Pretty much every customer ever Monday, October 3, 11 This is loosely based on typical real events. We’ve even had customers ship specific devices to us and still been unable to reproduce client-reported bugs.
  • 75. If I had a nickel for everything like that... Monday, October 3, 11 Sure, we test the heck out of things, but if I had a nickel for every time I heard something like...
  • 76. I could probably retire young. photo by Volker Neumann Monday, October 3, 11
  • 77. Even a well-stocked device library is never going to be able to represent the full gamut of what’s out there. Monday, October 3, 11 There are just too many combinations.
  • 78. And there are only so many hours in the day. Monday, October 3, 11 And just because you haven’t tested it doesn’t mean it’s not broken.
  • 79. Un-surmountable. Monday, October 3, 11 All this combines to make the mobile web feel unwinnable.
  • 80. It can’t go on like this.* * (But it likely will. For a while.) Monday, October 3, 11
  • 81. Monday, October 3, 11 The landscape feels pretty grim.
  • 82. Well, that was depressing. Now what? Monday, October 3, 11 That was quite an onslaught of the bleak. Did I bring you here to make you swear off the web forever?
  • 84. We can’t x everything right now, but by thinking in a future-friendly manner and relinquishing control we never had in the rst place, we can help shape the future of the web. Monday, October 3, 11
  • 86. Things we can do right now. Monday, October 3, 11
  • 88. Four considerations and four weapons you can use right now, in the short term. Monday, October 3, 11
  • 89. Consideration 1: Start to free your content. “Content like water” Monday, October 3, 11
  • 90. Monday, October 3, 11 Like I keep harping on and on and on about, we’ve had a habit of keeping our content in arbitrary cages, and we’re ignoring it at times, waylaid by the sound and fury of other distractions. It wants out. We can help liberate it by retooling our design practices.
  • 91. Monday, October 3, 11 These new practices are some rst steps to treating our content like water.
  • 92. Monday, October 3, 11 Opening the door to future greatness and content freedom.
  • 93. Old and busted. Monday, October 3, 11 The first mistake we often make when starting a new web site is to create a fixed-width, blank canvas in photoshop and start cramming crap into it to fill the spaces. Oftentimes, we ship off an approved mockup and never look back again. Implementation continues without revisiting the design assumptions.
  • 94. Monday, October 3, 11 Our tired, one-size-ts-a-few desktop web shoe doesn’t t the new generation.
  • 95. New hotness. Monday, October 3, 11 It’s time to get a bit smarter.
  • 96. Monday, October 3, 11 Updating the design process: Its about flex, flow and adaptation. Showing a bit more, telling a bit less.
  • 97. Do this. Instead of delivering static image-based comps at one or more “resolutions,” consider wireframes that demonstrate the !ow and !ex of content across a continuum of device and window sizes, indicating major breakpoints. Monday, October 3, 11 Static, pixel-specific mockups lock in unrealistic expectations with clients about the way the many-device web really works, and asserts that false control I keep whining about. Instead, newer design techniques use proportional, simpler-feeling wireframes that show the site adapting over a range of shapes, shifting flow more noticeably at defined breakpoints.
  • 98. Image from “Pragmatic Responsive Design,” Stephanie Rieger Monday, October 3, 11 This slide is from Stephanie Rieger’s great presentation about pragmatic responsive design, which I’ll provide a link to at the end of this presentation, showing breakpoints in a design her company, Yiibu, recently developed. Notice how the design adapts, and reflows to a certain extent at each defined breakpoint. There is no pre-determined set of breakpoints. They are per-project. Notice how the design scales between breakpoints, and then shifts noticeably at the breakpoints.
  • 99. Monday, October 3, 11 This kind of design gives your content the power to fill its own spaces, and is an element of Responsive Web Design, which I’ll come back to in a few moments. Like vector versus raster graphics, this design approach is about proportion and flexibility, not pixels and points.
  • 100. Do this. Build functional mockups—with HTML where possible—so that you can show (not tell). Monday, October 3, 11 Stay away from rigid mockups that lock in expectations with clients. Get your customers seeing the flow early and understanding the way that the design will adapt. Get yourself and your customers handling the early prototype mockups on devices as soon as possible.
  • 101. photo by Nick Thompson Monday, October 3, 11 Retune to design iteratively. No longer can you deliver design stuff once to a client and never look back.
  • 102. Do this. Work in tight, focused loops of iterative design to deal with inevitable, device-specic tweaks and inevitable client feedback. Monday, October 3, 11 Repetition and fine-tuning is inevitable in the state of the new web. Content informs design and as things shift, your design will need to adapt.
  • 103. Monday, October 3, 11 Granted, parts of this shift are a soft science, and hard for devs like me to glom onto easily. However, the conversation does need to be steered over time and our customers enlightened.
  • 104. Monday, October 3, 11 We need to help communicate where we’re putting our emphasis, and how flexible content that is adaptive is really a good plan for the future. It won’t sell itself overnight, but let’s start trying to talk about it. This is new stuff. We’re forging the future.
  • 105. Monday, October 3, 11 Oh, dear, so while we’re talking about honoring content, what about that problem with user- generated content and WYSIWYG editors and markup, oh, my!
  • 106. Monday, October 3, 11 There are a couple of bridging techniques you could use while we work toward fixing the content and CMS disaster. What I’m saying is: no one has fully solved this problem yet.
  • 107. Do this. Work with customers to build or adapt existing APIs to access or munge content. Monday, October 3, 11 WYSIWYG doesn’t really exist. Until we can afford to retool all of the existing, mired legacy systems out there, continue to fight the fight of separating content from presentation. On in- depth projects, work with customers to build APIs to access content and data. You’d be pleasantly surprised at how often APIs actually already exist, and how flexible customers’ dev teams can be about building or extending them.
  • 108. Do this. Consider less presentation- littered options like markdown or textile for existing CMSes. Monday, October 3, 11 But you can’t always build or use APIs. Another option is, for existing CMSes and less-than- techy editorial customers, more minimal markup concepts like markdown or textile, which keep presentation minimal in stored content, and also have the nice, future-friendly habit of being human readable.
  • 109. Consideration 2: Essentials first! Progressive enhancement isn’t just for the cool kids. It’s required. Monday, October 3, 11 Many of you may have heard of the Mobile First mantra. My colleague Luke W. is a leading proponent of this and has recently published an eponymous book. The idea of mobile first is to, well, design for mobile first, and expand that design out to enhance for larger or more powerful devices, e.g. the desktop.
  • 110. Mobile rst! Essentials rst! Monday, October 3, 11 I think we’re onto something with this idea, hugely, but that maybe the word “mobile”, again, is distracting us from what we’re really trying to accomplish. Maybe it’s more like essentials or baseline first.
  • 111. photo by seattle.roamer Monday, October 3, 11 Either way, the point is, we got fat and lazy in many way and we need to start trying to pare down our focus and get at what really matters in our web sites.
  • 112. Monday, October 3, 11 This is a bigger-picture thought process about simplification and focus. A mobile- or essentials-first attitude can help us go on a diet and figure out what really matters. It’s good for us, and It’s not just about mobile.
  • 113. Monday, October 3, 11 Finding serenity and meaning with your markup. Start from nothing. No JavaScript, no CSS. Figure out what content, services and functionality matter for every user. By starting simple, we avoid introducing (from the outset) complexity that will hinder our success, which is to work on as many devices as possible.
  • 114. Do this. • Get laser-sharp focus on your markup. Start with HTML. Believe in the HTML. • Essentials rst. Focus on semantics, clarity and simplicity. Is this the content that is core to all of your users? Monday, October 3, 11 Become extraordinarily friendly with the ins and outs of HTML5. This may seem like a no- brainer, but I think one of the things we’ll see in the near future, as a result of the desperate need for simplification, is some innovative approaches that build on rock-solid HTML5 and probably some more frameworks that can do some of the annoying stuff that is so hard for us.
  • 115. Consideration 3: Now, arm the weapons! Adapt, enhance and optimize: a bunch of tools for your arsenal. Here come some slides with text on them! Monday, October 3, 11 We’ve got our future-friendly HTML5 and we’re ready to do something with it. There are some tools out there to help simplify our lives and get our jobs done effectively. Some of these tools and ideas are bridging techniques until the world gets to be a bit of a safer place. Some are just great things.
  • 116. Engage weapon 1: Adapt and !ex with Responsive Web Design (RWD) Monday, October 3, 11
  • 117. Monday, October 3, 11 This is the article in A List Apart that introduced the idea of Responsive Web Design. Brainchild of Ethan Marcotte, Responsive Web Design combines several implementation techniques to bring to life the kind of flowing, adaptive layouts I’ve been talking about.
  • 118. Monday, October 3, 11 Using a combination of CSS 3 media queries, fluid grids and fluid images and media, we can build those flow-like-water layouts that adapt more easily across a lot of devices.
  • 119. 1: CSS 3 Media Queries @media all and (min-width: 480px) { } Monday, October 3, 11 There are three technical underpinnings to the RWD approach. A quick CSS 3 Media query primer for those who might not be initiated. CSS Media queries (one of the forty or so CSS 3 modules) let you selectively APPLY different CSS based on logical conditions. In this case, the CSS rules between the brackets are applied only if the window width is greater or equal to 480px.
  • 120. 2: Fluid media. img, object { max-width: 100%; } Monday, October 3, 11 With this simple CSS rule comes great power. This makes our images and embedded objects scale with the size of the containing element. Don’t forget that (at least not without great futzing) you can’t use width and height tags on images and objects managed in this way. This one really is this simple: just drop this rule into your CSS.
  • 121. 3: Fluid grids. • CSS layouts based on proportional elements. • Type in ems. • Widths in percentages. • Flexy, !exy! Monday, October 3, 11 If you’re not doing fluid layouts now, you should be. Learning how to do it takes about half an hour, and then you may find that your life is changed a bit for the shinier. Fluid grids use percentages for body element widths and ems for type (typically). What does this mean? It means that you’re not locking in any fixed units, and your design can scale. Fluid grids are a riff on flexible grids, which have been around for a while. You can learn how to make them by reading Ethan’s ALA article or his quick-read book.
  • 122. Monday, October 3, 11 In this simple responsive design I threw together, you can see how three columns collapse into one on a narrower screen. I’ve used a media query to apply different CSS based on screen width. The layout is a fluid grid, with element widths defined with percentages.
  • 123. Monday, October 3, 11 And also here, the use of fluid images allows the photo to scale with its container, fitting as well into the single-column layout as the multi-column layout.
  • 124. Monday, October 3, 11 Although there is a lot of hubbub about the specifics of RWD implementation (in fact, Cloud Four co-founder Jason Grigsby wrote a controversial post about media queries that has seriously made the rounds), try to let your mind float past the specifics about and meditate on the premise, which has a certain harmony. Borrowed to some extent from ideals of physical architecture, RWD is about flowing the content, adapting the environment around the user instead of trying to control the experience rigidly or making the user adapt.
  • 125. Do this. Use media queries to enhance layout. Avoid media queries in your baseline, reference implementation. Monday, October 3, 11 Consider media queries as an enhancement technique. That way you’re not relying on support in your baseline, content-is-king version. Hey, this is a great way of letting go of some crap to worry about!
  • 126. Do this. You may need to use shims for IE. But most desktop browsers are media-query-savvy. Monday, October 3, 11 You may need to use a JavaScript shim, if the media queries you’re making need to work in IE 7, 8 or whatever.
  • 127. Do this. Keep your eyes on your media and image (!le) sizes! Take a peek at Responsive Images (by Scott Jehl) or server-side techniques. Monday, October 3, 11 Just because you’re scaling images using the fluid technique doesn’t mean you’re out of the woods. You’re still delivering all of the bytes that are in the full-sized image.
  • 128. Do this. We’ve found that it’s OK (and relieves a bit of pressure) to leave a bit of unmanaged gutter (percentage) space in !uid layouts. Monday, October 3, 11 A lot of the tutorials out there for fluid grids have you accounting for every last scrape of room in the design, often resulting in, literally, percentages with 6 or 7 decimal places. At Cloud Four, we’ve found that we often avoid browser rounding difference issues and, really, just painful math, by allowing for a floating percentage or two to creep into the space of the design. Less precision-control, perhaps, but less likely to cause box-model rounding errors, esp. in IE.
  • 129. Target lock with weapon 2: Enhance and adapt with client-side feature detection Monday, October 3, 11
  • 130. Monday, October 3, 11 With client-side feature detection, you can ask questions like, hey, do you support the HTML5 audio tag? I’d like to drop in some sound!
  • 131. Monday, October 3, 11 These client-side feature detection tools ask the browser to tell us if it supports something right at this very second. Then we can enhance our content based upon the answer.
  • 132. Monday, October 3, 11 Modernizr is a prime contender in this space, and there are other cool polyfills, shims and tools like yepnope.js, adapt.js...
  • 133. Monday, October 3, 11 Sometimes it feels like there is a new JavaScript tool, library or framework every day. It can be hard for me to keep my house in order! But the up side is that there are tons of things to help you get your job done out there.
  • 134. Do this. Keep it e$cient. Use Modernizr’s new-ish modular approach to build your feature detection. Monday, October 3, 11 Don’t throw in the kitchen sink! This keeps your JavaScript payload size small and demands less of your user’s browsers and CPUs.
  • 135. Know this. Client-side feature detection works most of the time. But it is not infallible (have you noticed that nothing is?). Monday, October 3, 11
  • 136. Weapon 3: Rocking it old skool on the server side Monday, October 3, 11
  • 137. Monday, October 3, 11 You can do some heavy-lifting on the server side, some gearwork so that you’re not putting so much pressure on lighter clients.
  • 138. Server-side devs #represent • There are absolutely valid reasons that you might want to alter markup before you serve it to clients. Here are some words that start with “Re-.” • Reordering • Reduction • Respect Monday, October 3, 11
  • 139. User Agent Sni$ng photo by ex.libris Monday, October 3, 11 Sometimes user-agent sniffing gets a bum rap, but I’m done apologizing. In our wild world, there is often not another viable tool. Making our best estimates about an incoming device is not something only small-time folks do; most major websites that have mobile optimization are using device detection of some sort, and the vast majority of those hinge on user agent strings. It ain’t perfect, but it works.
  • 140. Device Databases photo by Tim Morgan Monday, October 3, 11 So, given a user agent string, how do we know more information about the client? That’s the job of device databases, which look up various capabilities based on, well, usually, a user agent string. We can make good first estimates about the resolution, browser version, video support, etc.
  • 141. Monday, October 3, 11 You gotta crack some eggs sometimes to make that tasty omelette. This isn’t about locking people out or dumbing down their content or locking them in to a particular view of content. There’s some nuance that can be used here.
  • 142. Do Don’t this. • Don’t be afraid to do some server-side optimization. Don’t let the bastards get you down. • Don’t overdo it. • Don’t leave folks out in the cold (without an escape mechanism). Monday, October 3, 11 Don’t this. And by combining server-side detection with clients-side detection, you can find considerably more nuance.
  • 143. Monday, October 3, 11 There’s also a bit of Zen in the combination of weapons 2 and 3, that is, using a server-side approach to make an educated first stab, and augmenting or correcting this guess with live, client-side feature detection. Bryan Rieger at Yiibu has done some very good work in this area...
  • 144. Killer Weapon #4: Optimize the hell out of it Monday, October 3, 11
  • 145. Do this. Huge, huge improvements can often be made in a couple of minutes by editing your .htaccess or apache conguration le. Monday, October 3, 11 You don’t get a get-out-of-jail-free card on this one. Performance on mobile matters more than ever. It’s amazing the massive performance improvements that can be made that are routinely overlooked by devs. These are simple changes that have huge impact.
  • 147. Do this. Get the YSlow extension for Firebug in your browser. Read it, study it, know it. Monday, October 3, 11
  • 148. GZip. Don’t even really consider not doing it. # Add gzip compression IfModule mod_deflate.c AddOutputFilterByType DEFLATE text/html AddOutputFilterByType DEFLATE text/plain AddOutputFilterByType DEFLATE text/xml AddOutputFilterByType DEFLATE text/css AddOutputFilterByType DEFLATE application/javascript AddOutputFilterByType DEFLATE application/x-javascript AddOutputFilterByType DEFLATE application/x-httpd-php AddOutputFilterByType DEFLATE application/rss+xml AddOutputFilterByType DEFLATE application/atom_xml /IfModule Monday, October 3, 11 I’m giving you some basically cut-and-pastable code for an .htaccess file so you can’t use the excuse that you don’t know how. This madly, madly cuts payloads.
  • 149. Far-future expires headers IfModule mod_expires.c # Enable expirations. ExpiresActive On # Cache all files for 2 weeks after access (A). ExpiresDefault A1209600 /IfModule Monday, October 3, 11 Tell browsers not to refresh content for a while; keep it cached. Be aware that when you’re turning this on, you’re kind of locking yourself into the file version. You’ll have to invent a file-naming convention to work around this.
  • 150. cache manifests AddType text/cache-manifest .appcache Monday, October 3, 11 I won’t lie. Futzing with cache manifests is a bit of a finicky business. You may need this in your apache config/.htaccess to make them work.
  • 151. cache manifests CACHE MANIFEST CACHE: /assets/fflogo.png /assets/signed.png /index.html /thinking.html /resources.html /styles.css NETWORK: * Monday, October 3, 11 Here’s the contents of the cache manifest on futurefriendly.
  • 152. IV. Now find places to draw the line. Letting go and finding a bit of balance. Monday, October 3, 11
  • 153. Plant the seed early. Monday, October 3, 11 Plant the seed early. As much as I loathe the expression: “Set expectations.” Learn to talk about what devices can and cannot do, how browsers break, and how you can’t control everything.
  • 154. Take note of when you get mired. Monday, October 3, 11 Sometimes when you’re deeply in dev, you can’t see the forest for the trees. Learn to recognize when you’re mired. Take note. Try not to chase your tail quite as much.
  • 155. Don’t fear the occasional egregious hack. Monday, October 3, 11 Don’t be afraid to pull out an egregious hack or two. Use your best duct tape programming skills, as per Joel Spolsky.
  • 156. Put your energy into the devices that “matter.” Monday, October 3, 11 Focus on the devices that matter. That doesn’t mean to do this at the expense of everyone else, but don’t get mired in small tweaks for every single thing out there.
  • 157. Fail with grace. Monday, October 3, 11 Be ready to fail gracefully a bit when you set your site free. You have the good underpinnings there to fall back on.
  • 158. And what about the future? Looking further ahead. Monday, October 3, 11
  • 159. Disruption will only accelerate. The quantity and diversity of connected devices—many of which we haven't imagined yet—will explode, as will the quantity and diversity of the people around the world who use them. Our existing standards, workflows, and infrastructure won't hold up. Today's onslaught of devices is already pushing them to the breaking point. They can't withstand what's ahead. Proprietary solutions will dominate at first. Innovation necessarily precedes standardization. Technologists will scramble to these solutions before realizing (yet again) that a standardized platform is needed to maintain sanity. The standards process will be painfully slow. We will struggle with (and eventually agree upon) appropriate standards. During this period, the web will fall even further behind proprietary solutions. http://futurefriend.ly Monday, October 3, 11
  • 160. Emancipating mobile browsers from the ghetto. Monday, October 3, 11 What does this mean? For one thing it means changing the conversation that has...
  • 161. Changing the conversation. Monday, October 3, 11 Changing the conversation? Yes, right now the tone is slightly odd. As devs, we consider it our responsibility to deal with the myriad, weird, specific, quirky device and browser bugs. We should try to slowly turn this conversation back around and make the onus on device and OS and browser makers—the people who actually have control over this—make things work as advertised, and deliver on promises.
  • 162. Be future friendly. Monday, October 3, 11 Some of the considerations I talked about run parallel to the future friendly ideals. We’re still ironing out the kinks.
  • 163. We can steer this ship. Monday, October 3, 11 We’re not totally sure exactly what the future looks like. But by thinking in a future-friendly manner, you can help get the ship on track.
  • 164. Victory can be ours. Monday, October 3, 11 I believe that, though the ride will be bumpy for a while, the increasing chaos will eventually reach a tipping point—at least I hope so.
  • 165. Remember, this isn’t religion. Monday, October 3, 11 And we’re all on the same team. Don’t let yourself get caught up in over-idealized squabbles. Let’s work together.
  • 166. Monday, October 3, 11 Set it freeeeeee!
  • 167. Must-Reads • All of the resources on http://futurefriend.ly/resources.html • “Pragmatic Responsive Design” Stephanie Rieger http:// www.slideshare.net/yiibu/pragmatic-responsive-design • Responsive Web Design, Ethan Marcotte http://www.abookapart.com/ products/responsive-web-design • Mobile First, Luke Wroblewski, http://www.abookapart.com/ products/mobile-first • “Meta Layout: A Closer Look at Media Queries”, Stephen Hay http://www.slideshare.net/stephenhay/mobilism2011 • “Rethinking the Mobile Web” Bryan Rieger http:// www.slideshare.net/bryanrieger/rethinking-the-mobile-web-by- yiibu • “The Duct Tape Programmer” Joel Spolsky http:// www.joelonsoftware.com/items/2009/09/23.html Monday, October 3, 11
  • 169. Thanks for enduring me! Lyza Danger Gardner lyza@lyza.com @lyzadanger Photos ‘n stu# in this presentation are mine unless otherwise noted Youcanuse‘em too(Creative Commons) Monday, October 3, 11