RFC: Implement Prerender for older Browsers and Google RFC2021-03 #1314
-
We just published our first simple Oqtane site and tried to see what google would see - it's an empty page. I assume this is also what older browsers would get and makes Oqtane sites impossible to get into google. I'm aware that this is not the primary use case as of now, but I believe it would be great to enable this - and I think it's not too hard. I did some research and found out that it should be fairly easy to enable Prerendering in Blazor:
From my understanding it would take a bit of work, but I believe it could be done in a day or so. We (2sic) would also volunteer to spearhead this if this would make it into Oqtane once it works. What are other opinions on this? |
Beta Was this translation helpful? Give feedback.
Replies: 8 comments 35 replies
-
I always avoided SPA frameworks like Angular because of bad SEO/Crawler compatibility. If Blazor does support pre-rendering then it would be great if Oqtane also support it. |
Beta Was this translation helpful? Give feedback.
-
Could be related to discussion Oqtane runtime configuration #1223 - just for your information. With 2sxc 12 Hybrid for Oqtane #1312 Oqtane has become a CMS too ;-) |
Beta Was this translation helpful? Give feedback.
-
I would strongly support this. The fact that Oqtane is first and foremost an application framework, doesn't mean it should not support prerendering. This is not only good for the oddball that DOES want to use as a CMS, but also even for internal enterprise use, where a company crawler may visit an application to show the most recent screenshots in a library of apps etc etc. |
Beta Was this translation helpful? Give feedback.
-
As I mentioned in #1233 I recently did some testing and changed the render-mode in _Host.cshtml from
to
and the framework ran just fine without any errors or behavioral issues - and produced pre-rendered output. I do not see any reason to prevent making this change in Oqtane. Note that .NET6 will take this even further... which is something that can be considered when NET6 actually ships: https://jonhilton.net/blazor-prerendering-net6/ |
Beta Was this translation helpful? Give feedback.
-
same here, had to rollback But, fresh install runs ok. |
Beta Was this translation helpful? Give feedback.
-
@leigh-pointer I think I might have an idea on what is causing this... we recently modularized each database provider so that they can be installed independently ( ie. so that if you are not using a specific database provider it will not consume any system resources ). This is working for new installs... but for upgrades where you are already using either LocalDB or SQL Server from a past installation, I have a feeling that it is not ensuring the provider is installed before proceeding. Perhaps @cnurse can confirm. |
Beta Was this translation helpful? Give feedback.
-
When the upgrade fails and returns (for me, to Visual Studio) the appsettings is an empty file wilth just the empty nodes (new install) |
Beta Was this translation helpful? Give feedback.
-
Clean 2.1.0 with a 2.0.2 database. Updated the appsettings to reflect the database connection and added the "DefaultDBType": "Oqtane.Database.SqlServer.SqlServerDatabase, Oqtane.Database.SqlServer". Started VS as waited, for sometime. no response. Entered the local host addess and received. An error occurred while starting the application. ArgumentNullException: Value cannot be null. (Parameter 'type')
|
Beta Was this translation helpful? Give feedback.
As I mentioned in #1233 I recently did some testing and changed the render-mode in _Host.cshtml from
to
and the framework ran just fine without any errors or behavioral issues - and produced pre-rendered output. I do not see any reason to prevent making this change in Oqtane.
Note that .NET6 will take this even further... which is something that can be considered when NET6 actually ships: https://jonhilton.net/blazor-prerendering-net6/