DotVVM.AMP 0.2.0

There is a newer version of this package available.
See the version list below for details.
dotnet add package DotVVM.AMP --version 0.2.0
NuGet\Install-Package DotVVM.AMP -Version 0.2.0
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="DotVVM.AMP" Version="0.2.0" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add DotVVM.AMP --version 0.2.0
#r "nuget: DotVVM.AMP, 0.2.0"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install DotVVM.AMP as a Cake Addin
#addin nuget:?package=DotVVM.AMP&version=0.2.0

// Install DotVVM.AMP as a Cake Tool
#tool nuget:?package=DotVVM.AMP&version=0.2.0

DotVVM.AMP

DotVVM.AMP allows easy automatic conversion of certain DotVVM pages to AMP pages. The page must meet several basic criteria to work without any further configurations / modifications:

  1. No postbacks ale allowed.
  2. No external JavaScript is present.
  3. All the CSS code is under 75 kB and does not include any !important directives.

How to use on complex pages

When all those criteria are met, then the only thing left to do is to mark the route as AMP ready and enjoy lighting fast performance. Event if you page does not fit the abovementioned criteria, then you can use DotVVM.AMP. The DotVVM.AMP can be set up to ignore invalid parts and the DotVVM view can be slightly modified to mark the sections of the page which will be included only in the DotVVM page or only in the AMP version.

How to use

Number of steps needed to use transform some of you DotVVM pages into AMP is small and they are easy to follow:

  1. Add DotVVM.AMP nuget package into your application.
  2. Modify DotvvmStartup.cs
  1. Call AddDotvvmAmpSupport on IDotvvmServiceCollection instance. In this method you can configure DotVVM.AMP. You can for example configure how invalid constructs are handled.
  2. Call AddDotvvmAmp on DotvvmConfiguration instance.
  3. Modify route table registrations for routes, for which you want to have their AMP version, to use AddWithAmp instead of default Add method.
  1. Profit

In case that the AMP version does not work as expected, then you can try following steps to get it up and running:

  • You can exclude unsupported parts via <amp:Exclude> and <amp:Include> controls.
  • You can use resource binding instead of value binding when possible.
  • You can set handling mode for the type of error you are getting from Throw to LogAndIgnore. With this setting the error would be logged and DotVVM.AMP will try to solve or ignore the problem.
Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.0 was computed.  netcoreapp2.1 was computed.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
.NET Standard netstandard2.0 is compatible.  netstandard2.1 was computed. 
.NET Framework net461 was computed.  net462 was computed.  net463 was computed.  net47 was computed.  net471 was computed.  net472 was computed.  net48 was computed.  net481 was computed. 
MonoAndroid monoandroid was computed. 
MonoMac monomac was computed. 
MonoTouch monotouch was computed. 
Tizen tizen40 was computed.  tizen60 was computed. 
Xamarin.iOS xamarinios was computed. 
Xamarin.Mac xamarinmac was computed. 
Xamarin.TVOS xamarintvos was computed. 
Xamarin.WatchOS xamarinwatchos was computed. 
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
0.2.2 591 8/17/2021
0.2.1 380 8/3/2021
0.2.0 387 7/8/2021
0.1.9.5 360 7/6/2021
0.1.9.2 382 1/18/2021
0.1.9.1 470 1/7/2021
0.1.9 476 10/3/2020
0.1.8 541 9/26/2020
0.1.7 560 8/13/2020
0.1.6 481 8/13/2020
0.1.5 482 8/12/2020
0.1.1 547 5/23/2020
0.1.0.7 526 5/16/2020
0.1.0.6 516 5/15/2020
0.1.0.5 488 5/15/2020
0.1.0.4-pre 341 5/4/2020
0.1.0.2-pre 333 4/28/2020
0.1.0.1-pre 339 4/28/2020

Updated to DotVVM 3.1