Skip to main content

Posts

Showing posts with the label Mobile

Progressive Web App–Icon is not loaded

Progressive Web Apps (PWAs) are web apps that use service workers , manifests , and other web-platform features in combination with progressive enhancement to give users an experience on par with native apps. An important building block in transforming your web application into a PWA is the web application manifest . This is a JSON text file that provides information about a web application that the browser needs to install your PWA on a device, such as the app's name and icon. For one of our PWA’s we noticed that the image icon was not loaded. In the browser console, we noticed the following error message: If we take a look at the manifest file itself, it looks OK: And the used image is available in a subfolder relative to the manifest file: What turns out to be the problem is that our application is running in a virtual directory, e.g. https://example.com/application/ . Although the manifest.json file is hosted at that path, the browser tries to load the images f...

PWABuilder - the simplest way to create progressive web apps across platforms and devices

Last month, a new version the PWABuilder , a community project led by Microsoft was released. PWABuilder is a PWA that easily takes a normal web app / web site and transforms it to a PWA. PWABuilder 2.0 introduces the following new features: A new more user friendly design New snippets to support newer API's such as the Web Share API and the async Clipboard API To get started browse to www.pwabuilder.com and enter the URL of your website: After entering an URL, hit start and the PWABuilder app will scan your website for the availability of a manifest, serviceworkers and https, all prerequisites to have a PWA. If any of these things are missing, the tool will report this and provide you with snippets and an example manifest to get started:

Learning PWA’s - Service Workies

Progressive Web Apps are evolving quite fast and Google is leading the initiative. At Chrome Dev Summit 2018 they reconfirmed the message that the future of PWA’s is looking great. With deeper OS integrations, improved speed and upcoming new capabilities , the gap between native and PWA will possible be closed faster than we think. So time to start learning about PWA’s and no better way to learn something than through gamification. Dave Geddes , who created Flexbox Zombies and CSS Grid Critters, created a new learning game. Service Workies helps you understand Service Workers soup to nuts. The first chapter of the adventure is rolling out in beta now. Google partnered with Dave to make sure the full adventure can be free to all.

Ionic Build – Gradle throws “Could not reserve enough space for object heap” error

Compiling and running an Ionic application on your Android device is a whole lot of fun, requiring a big list of tools and a little bit of good luck. It seems that I was out of luck as I got the following error message during the startup of Gradle: Could not reserve enough space for object heap To solve it, I specifically downloaded and installed the 64bit version of Java: After the installation completed, I updated my JAVA_HOME environment variable to point to the 64bit version:

Mobile vs Web: https://whatwebcando.today/

With the introduction of Progressive Web Apps, the discussion if web applications can and will replace native mobile applications has started all over again. To feed the discussion, have a look at https://whatwebcando.today/ and decide for yourself if you can rely on the Web Platform features to build your next mobile application…

Progressive Web App–Redirect from HTTP to HTTPS

I’m currently working on a Progressive Web App(PWA) using ASP.NET Core. After creating our initial setup I used the Google Lighthouse chrome extension to check my application. The results looked OK, I only had one failed audit: “Does not redirect HTTP traffic to HTTPS”. Let’s fix this by adding the AspNetCore Rewrite middleware: If you need to specify a port, you can add some extra parameters:

The Microsoft Azure App

While getting up to date with all the great announcements at Build 2017 I noticed a small but interesting fact. It turns out that Microsoft has a mobile app (for iOS and Android ) that allows you to manage Azure from your mobile device.   From the documentation: The Microsoft Azure app helps you keep track of your resources while on-the-go: - Stay connected to the cloud and check status and critical metrics anytime, anywhere - Stay informed with notifications and alerts about important health issues - Stay in control of your resources and take corrective actions, like starting and stopping VMs and web apps Great! Now can I spin up a new VM while being stuck in traffic

Xamarin.Forms: Error CS1703 Multiple assemblies with equivalent identity have been imported

When trying to build our Xamarin.Forms project on a VSTS hosted build server, our build failed first with the following error message: Error CS1703 Multiple assemblies with equivalent identity have been imported: ‘C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\MonoAndroid\v1.0\mscorlib.dll’ and ‘C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319\mscorlib.dll’. Remove one of the duplicate references. On our local system it worked without any compiler errors. We tried the easiest solution first, following the advice as mentioned in the error message. We removed the mscorlib.dll from the references. After doing that, everything was working again. I hate it when the behavior differs between a local Visual Studio Build and the build server

Updating Xamarin in Visual Studio

After the announcements of the new Xamarin updates, I thought time to update! And indeed when opening Visual Studio a notification appeared telling me an update was available. But after clicking on the notification I couldn’t find how to initiate the update … Turns out that this is actually not that hard: Inside Visual Studio, click on Tools –> Options Search for Xamarin in the Options menu Select Other and click on Check Now to find and install available updates.

Creating a release pipeline for your mobile applications

I’m currently working on a release pipeline for our mobile applications, making it easy to build, deploy and test the mobile solutions we are creating on top of the Xamarin platform. Everyone who ever tried to publish a mobile application to a store(Apple AppStore, Google Play Store, Microsoft App Store,…) knows that it is cumbersome process requiring things like certificates, keystores, a lot of configuration work and so on… To optimize the process we went fully automated by using a combination of the following tools: Visual Studio Team Services Hosted Build Service MacInCloud Xamarin Test Cloud HockeyApp A great help during our journey was the DevOps blog series by Richard Woollcott: Xamarin DevOps VSTS – Getting Started: http://www.thexamarinjournal.com/xamarin-dev-ops-with-vsts-getting-started/ Xamarin DevOps with VSTS - Setup iOS CI Builds With MacinCloud: http://www.thexamarinjournal.com/xamarin-dev-ops-with-vsts-setup-ios-ci-builds-with-macinc...

Xamarin Evolve 2016–Videos available

If you were one of the lucky guys/girls who attended Xamarin Evolve , you can ignore this post. For all other people, the videos from all sessions at Evolve are published yesterday. So time to free some time in your agenda, close the curtains, get some good popcorn and start learning…!

Xamarin error - Could not load assembly 'Xamarin.Android.Support.v4'

After upgrading my Visual Studio to the latest version, I couldn’t compile my Xamarin project anymore. Instead I got the following error: Severity    Code    Description    Project    File    Line    Suppression State Error        Exception while loading assemblies: System.IO.FileNotFoundException: Could not load assembly 'Xamarin.Android.Support.v4, Version=1.0.0.0, Culture=neutral, PublicKeyToken='. Perhaps it doesn't exist in the Mono for Android profile? File name: 'Xamarin.Android.Support.v4.dll'    at Xamarin.Android.Tuner.DirectoryAssemblyResolver.Resolve(AssemblyNameReference reference, ReaderParameters parameters)    at Xamarin.Android.Tasks.ResolveAssemblies.AddAssemblyReferences(ICollection`1 assemblies, AssemblyDefinition assembly, Boolean topLevel)    at Xamarin.Android.Tasks.Resolve...

Adventures in Xamarin Forms

With the recent announcement that Microsoft is buying Xamarin, I thought it was time to have a second look at Xamarin Forms(I took a first look more then a year ago, so hopes are that it evolved a lot in the meanwhile). The most interesting resource I could find is the Adventures in Xamarin Forms blog by Jonathan Yates in which he describes the lessons he learned while creating the Mountain Weather application.

Xamarin.Forms: Xamarin-Forms-Labs

The amount of controls for Xamarin.Forms is rather limited. Luckily with the help of the community and control vendors like Telerik, Syncfusion,etc… this is changing. One of the open source initiatives is Xamarin-Forms-Labs : “Xamarin Forms Labs is a open source project that aims to provide a powerful and cross platform set of controls and helpers tailored to work with Xamarin Forms” It offers a wide range of controls, services, helpers and plugins. A must have for every Xamarin.Forms developer… Available controls AutoComplete (beta) Calendar Control (beta) Checkbox (beta) DynamicListView (beta) ExtendedContentView (beta) ExtendedEntry (beta) ExtendedLabel (beta) ExtendedScrollView (IOS beta) ExtendedTabbedPage ExtendedTextCell (beta) ExtendedViewCell (beta) HybridWebView (alpha) GridView (IOS beta) ImageButton (beta) RadioButton(beta) RepeaterView (beta) SegmentedControlView (IOS beta) Web Image (beta...

Xamarin.Forms: No valid iOS code signing keys found in keychain

Yesterday while creating a new Xamarin.Forms application,  it failed to build for iOS with the following error message: No valid iOS code signing keys found in keychain I first thought that there was something wrong with my iOS configuration, but when I tried to create a ‘traditional’ iOS application, it just worked. On the Xamarin forums I found the following solution that worked for me: Open your Xamarin.Forms projects. Unload the iOS project in Visual Studio. Open the csproj file and search for the following element <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' ">     <CodesignEntitlements>Entitlements.plist</CodesignEntitlements> </PropertyGroup> Remove ‘ Entitlements.plist’ from the ‘CodesignEntitlements’ <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|iPhoneSimulator' "> <CodesignEntitlement...

Techorama 2015: RequestBin

Always great to discover the tools that other people use during their presentations. It are these moments that make visiting a conference worthwhile and allow you to earn your money back big time! During Techorama 2015, one of the speakers was using RequestBin : RequestBin gives you a URL that will collect requests made to it and let you inspect them in a human-friendly way. Use RequestBin to see what your HTTP client is sending or to inspect and debug webhook requests. It’s the perfect solution when you want to see what’s send to the server but are not able to trace and inspect the HTTP requests on the server. Click on the Create a RequestBin button: Copy the generated url into your HTTP client (like curl for example). Execute a call: And check the results on the RequestBin website: Nice!

Xamarin Forms Succintly

The Syncfusion ‘Succintly’ collection of free e-books keeps growing. The latest addition is  Xamarin.Forms Succintly . It is available for free here (registration required). Xamarin.Forms Succinctly With the fragmented landscape of mobile device platforms, tools for creating cross-platform apps have sprung up as varied and numerous as apps themselves. Most of these tools create their own APIs and translate them into the mobile platform APIs, which works fine for some. And then there’s Xamarin.Forms, which creates mappings from its C# classes and controls directly to the native platform APIs and controls. With Xamarin.Forms Succinctly by Derek Jensen, you will learn how to use Xamarin.Forms to build a common code base that can be deployed to iOS, Android, and Windows Phone devices, coming as close as possible as to the mythical “write once, run everywhere.” You’ll also learn how to build UIs with some of the 40 controls included in Xamarin.Forms, and even how to access na...

ASP.NET Web API Request Batching

Most applications I’m building today are using a kind of Web API. This works great, but leads to chatty interfaces, requiring a  large number of requests to get all the required data. In situations where the API is only for internal usage and you don’t want to share it with other applications, your application can benefit from a technique called ‘Request Batching’. Remark: Be aware that Batch requests are not REST-compliant. So if you are creating a public API stop reading… What is it? Request batching combines multiple API requests into a single POST request. HTTP provides this out-of-the-box using a special content type called Multipart . On server-side, requests are unpacked and dispatched to the appropriate API methods. All responses are packed together and sent back to the client as a single HTTP response. The nice thing is that it is already supported by ASP.NET web API and you don’t need a lot of extra code to get it working. Enable Request Batching in ASP.NET Web...

Mobile Development Platform Performance Comparison

When choosing a development platform for building Mobile applications, performance is always one of the discussion points pro- or contra a specific technology. A lot of people claim that technology X is faster than technology Y without real numbers to proof their point. I did some tests myself and had mixed experiences using Cordova, Xamarin and Native Mobile development. Last week I noticed this blog post by Kevin Ford: http://magenic.com/Blog/PostId/67/mobile-development-platform-performance . Kevin took the time to create a formal comparison between Native (Objective-C 64 bit and Java) Cordova (Multi-Device Hybrid Apps) using Intel's App Framework for the UI Classic Xamarin (64 bit unified beta for iOS) Xamarin.Forms (64 bit unified beta for iOS with beta version of Xamarin.Forms, note latest version of the unified API in the beta/alpha channels could not be used as it is not supported by Xamarin.Forms) Go check out the full post for all the details, but some things...

Free ebook – Perspectives on Agile Software Testing

In celebration of the 10th anniversary of Selenium, the guys from Thoughtworks created a small ebook available for free: It's been 10 years since Selenium was born and the industry has changed tremendously since then. In honor of Selenium's first decade, we put together some our greatest hits and new pieces on software testing. How has testing evolved in the past decade? How do we adapt to the new challenges that mobile testing has to offer? Can testing in an agile environment lead to faster feedback? Download this free e-book and read more about the big developments in testing methods and tools, while looking closely at the advent of mobile testing and what the future holds for QAs.   The book can be downloaded here: http://info.thoughtworks.com/ebook-agile-software-testing . Remark: Be aware that you have to register first.