Quantcast
Channel: Damir's Corner
Browsing all 484 articles
Browse latest View live
↧

Reusing parts of XAML with Xamarin.Forms

Custom controls are the most common way for reusing parts of markup in Xamarin.Forms. When displaying collections, data templates can often serve as a simpler alternative with less overhead:...

View Article


Updating external data sources in SQL Server

I recently had to create a copy of multiple Azure SQL databases. They were all interconnected, i.e. each database had some other databases registered as external data sources. After the import, these...

View Article


Image may be NSFW.
Clik here to view.

Creating and publishing a Greasy Fork script

I've been using a couple of GreasyFork scripts with Tampermonkey Firefox extension for a while. Only recently has a missing feature on a web page bothered me enough to consider creating a user script...

View Article

Configuring Angular for older browsers

In recent versions, Angular is preconfigured for an ES2015 build which only works in modern browsers. Often, that's not an issue. Fortunately, it's still possible to make it compatible with older...

View Article

Image may be NSFW.
Clik here to view.

Using SCSS variables in Angular

When creating a new project using Angular CLI you can choose to have SCSS support in the project preconfigured. But even if you do, it doesn't set up any file for the rules that will be reused across...

View Article


Image may be NSFW.
Clik here to view.

Xamarin.Forms FlyoutHeader and iOS safe area

In Xamarin.Forms Shell, the flyout header is always positioned at the top of the flyout even if not all menu items fit on the screen and scrolling is required. It's a great place to show an application...

View Article

Image may be NSFW.
Clik here to view.

Multiple Hangfire instances in one database

I recently got involved in maintaining a project that's using Hangfire for scheduling jobs. One of the issues with it was unreliable execution of jobs. Often, they failed several times before finally...

View Article

Image may be NSFW.
Clik here to view.

Configuring environments in .NET console app

ASP.NET Core applications are already set up with support for reading configuration files and switching between different environments. You get none of that when you create a new .NET console...

View Article


Return value from Xamarin.Forms Shell modal

Xamarin.Forms Shell makes navigation in Xamarin.Forms apps much simpler by using URL based routes instead of the NavigationPage-based hierarchical navigation. It works well even for modal pages. You...

View Article


Image may be NSFW.
Clik here to view.

My PowerShell prompt configuration

I like doing things from the command line and use PowerShell daily. I miss some features in the default Windows PowerShell console and use Windows Terminal and Oh my Posh to improve the experience....

View Article

Unreliable navigation to root page

Xamarin.Forms Shell navigation seems well documented but either I don't understand the documentation correctly or it isn't accurate. The part that confuses me is the description of the following two...

View Article

Image may be NSFW.
Clik here to view.

Displaying toasts in Xamarin.Forms

Toasts are a common way to non-intrusively show information to the user. Unfortunately, there's no built-in control for them in Xamarin.Forms. I also couldn't find a dedicated third-party library with...

View Article

Synchronous async method implementation

Interfaces usually have methods that return tasks because they were designed to be asynchronous. But how should you implement such a method when you don't need to call any asynchronous methods inside...

View Article


Awaiting Google Play services tasks

Thanks to Xamarin, C# developers can use a lot of their existing knowledge even when interacting with native Android (and iOS) APIs. However, some APIs still break the idioms we're used to in .NET. For...

View Article

Changing URLs of Git submodules

I prefer using Git over SSH which makes me a minority in most teams I work with. Fortunately, the way I connect to the repository usually doesn't matter, as all Git hosting services support both HTTPS...

View Article


What code are your unit tests testing?

Mocks can be a helpful tool for replacing external dependencies in unit tests. However, caution is required when you embark on that route or you could end up with tests that don't really test your code...

View Article

Fun with JavaScript type coercion

Type coercion is the term used for automatic conversion between data types in JavaScript. If you're not careful, it can be a cause for subtle bugs in your code. This post is dedicated to one such...

View Article


Use more client-side libs with Nuxt SSR

Server-side rendering is a great way to make your NuxtJS site more SEO-friendly, as it sends a fully rendered page to the client. However, this doesn't work with libraries that require access to DOM...

View Article

404 page for Nuxt dynamic nested routes

Although NuxtJS routing is based on the file system, it also supports dynamic routes that are unknown in advance and based on an external data source. Unknown dynamic nested routes even allow this for...

View Article

Image may be NSFW.
Clik here to view.

Allowing insecure WebSocket connections

Increased security in web browsers can be a hindrance during development when all the infrastructure is not yet in place. For example, browsers don't allow insecure WebSocket connections (ws) from...

View Article
Browsing all 484 articles
Browse latest View live