VGTech is a blog where the developers and devops of Norways most visited website share code and tricks of the trade… Read more



Are you brilliant? We're hiring. Read more

App linking in Android M and iOS9

Android

The next versions of both Apple and Googles mobile operating systems (iOS9 and Android M) will have dramatic consequences for publishers trying to get users to use their mobile app instead of the mobile web browser. The next version of the iOS and Android operating systems will take deep linking to a new level.

Both Apple and Google have worked simultaneously on improving app linking, and essentially blurring the lines between content displayed in an app and content in a mobile website.
Users will be accustomed to searching at the operating system level (either through voice or touch input) in future versions of mobile operating systems, the search results will display web, app and local file results. The browser will not necessarily be the starting point for searching for content and users will be accustomed to search results displaying content available in apps, websites and local files.
(more…)


Android Databinding: Goodbye Presenter, hello ViewModel!

Android

The Model-View-Presenter-pattern (MVP) has been the dominating trend lately when it comes the UI-layer architecture of Android applications. Frameworks like Ted Mosby, Nucleus and Mortar have all talked about Presenters to help you achieving a clean architecture of your app. They also (to a varying degree) help you with the infamous issues of device rotation and state persistence on the Android platform. This isn’t directly related to the concept of MVP, but the pattern helps you isolate the boiler plate code.
(more…)


Logo redesign and the thoughts behind

Design

Vektklubb is the largest weight loss service in Norway, owned by VG. The goal is to help people loose weight by eating healthy food and exercise. No diets, no starving. We believe that changing habits over time is key to achieve a better and healthier lifestyle. The service has been around for ten years, and is still going strong! However, last year it was time for a makeover.

Vektklubb-logo-before-after

 

(more…)


Location based Ads at VG

At VG we have been experimenting with offering location based advertisements in our VG app.

The goal is to deliver relevant advertisements to the the users at the right time and in the right place. Smartphones have provided the opportunity to serve more relevant information based on a users current physical location or locations they have previously visited.

(more…)


Don’t forget the View Model!

Android

Background

I’ve observed an increase in architecture-focused Android posts lately in channels such as /r/androiddev and Android Weekly. That’s great, but frankly it’s about time. When I transitioned from Windows Phone development to Android a couple of years ago I felt it was difficult to find good examples on how to architect a solid app. It didn’t help that Google’s examples violated most best practices[1] either. I kind of went with my own version of MVVM (or MVPVM) which I had with me from the .NET platform and it sort of worked. Reading
Hannes Dorfmann’s post on MVP and his Mosby framework, I realize I’m not the only one who’ve been struggling with getting the established patterns working with Android (he spent 3 years). The Android SDK is not exactly leading you into a good architecture out of the box. Maybe Fragments is partly to blame, and why Square Inc is advocating against it. (more…)


Product Management In Media

Media companies where journalists and technologists don’t get on the same page regarding product and product management will die.

Tl;dr — Unless media companies step it up and totally change their view and abilities on product management, they will be eaten by tech and new players. Only those that fully embrace that product management in media is the intersection between journalism, user experience, software, data and analytics will thrive.

The ability media companies have to innovate and compete in this tech-eats-everything-world is fully dependent on how they view product and product management. As of now, it seems very few (traditional) media companies are able to agree on these terms internally.

(more…)


The current state of the Wearable industry

Wearables

The wearables space is quite broad and includes everything from fitness trackers, smartwatches, augmented reality glasses, smart jewellery, smart clothes and even implants. Its all about the connected self and the use of this new technology to do things like monitor your health, to play games, to make you fitter, to save you time or to make you more organised.

The industry is still lacking a killer feature, platform or device that can rejuvenate this market. Everyone is looking to the soon to be released Apple watch to do to wearables what it did for the mobile industry.

Below are some examples of how wearables are being used today.

(more…)


Clean and simple Z-index with SASS lists

CSS

So.. Z-index. Ever used it on a rather large scale site before? Or in a CSS environment that you don’t really know inside out? What number did you set? Did you make it really, really high just to be sure? Ever used z-index: 100003? Or 99999999?

Highest z-index was an astonishing 999999999999999999999999999 or 9.99e26. With a default key repeat on OS X, this would take 3 seconds of holding down 9 to type.

QuickLefts 2014 CSS report

You don’t do that, right? Perhaps you rather build systems with levels set in hundreds or thousands, to be able to sneak in future elements? The oddball z-index: 1005; here and there?

For my latest project I used a rather simple trick in SASS that got me out of this potential mess, and I didn’t even set a single number. SASS took care of that for me! (more…)


JavaScript Code Style

JS

Code is read much more often than it is written. Having a consistent and defined coding style helps developers read the code, and it also helps to make a code base feel like one unit, instead of individual pieces written by different authors with their own way of doing things.

Having a coding standards is beneficial, but making people follow it is usually a bit harder. Let me introduce two awesome tools to help you: JSHint and JSCS. (more…)


Writing, testing and publishing Javascript modules

JS

So you want to write reusable, maintainable and modular Javascript, huh? Good.

Here’s a rather extensive “getting started”-guide by yours truly – which means it’s my own preferred way of doing things. It’s written with open-source in mind, but most points can be applied to “private” modules as well.

(more…)