您的位置:首页 > 其它

软件项目-1.4_微软开源Blazor

2018-02-24 10:02 337 查看
Blazor介绍
微软的ASP.NET团队宣布了一个名为Blazor的新项目,它是一种基于流行语言C#,Razor和HTML的实验性Web UI框架,Blazor是Browser + Razor的组合。
Visual Studio产品系列在Windows,Linux和MacOS上提供了一个很好的.NET开发体验。Blazor是一个构建在.NET上的单页Web应用程序框架,通过WebAssembly在Web浏览器中运行。
Blazor应用程序类似于也在Web浏览器中运行的渐进式Web应用程序。它虽然使用诸如CSS 和HTML 之类的Web 技术,但它使用 C#语言和 Razor 语法代替 JavaScript 来构建可组合的 Web UI 。通过提供用于编译到 Web 的大小和高效加载的格式,WebAssembly 可让 .Net 在浏览器中运行。
 
Blazor框架具备功能,包括:
用于构建 composable UI 的组件模型
路由
布局
表格和验证
依赖注入
JavaScript 互操作
开发期间在浏览器中实时重新加载
服务器端渲染
在浏览器和 IDE 中全面调试 .NET
能够通过 asm.js 在较早版本的(非 WebAssembly )浏览器上运行
Sanderson's Blog
http://blog.stevensanderson.com/2018/02/06/blazor-intro/
Running .NETin the browser
The first step to building a .NET-based SPA frameworkis to have a way of running .NET code inside web browsers. We can at last dothis based on open standards, supporting any web browser (without any plugins),thanks to WebAssembly.
 
WebAssembly is now supported by all mainstreambrowsers, including on mobile devices. It’s a compact bytecode format optimisedfor minimum download sizes and maximum execution speed. Despite what a lot ofdevelopers first assume, it does not introduce new security concerns, becauseit isn’t regular assembly code (e.g., x86/x64 or similar) - it’s a new bytecodeformat that can only do what JavaScript can do.
 
So how does that let us run .NET? Well, the Mono team isadding support for WebAssembly. In case you missed the news, Monohas been part of Microsoft since 2016. Mono is the official .NET runtime forclient platforms (e.g., native mobile apps and games). WebAssembly is yetanother client platform, so it makes sense that Mono should run on it.
Mono aims to run under WebAssembly in two modes:interpreted and AOT.
 
以上引用Sanderson'sBlog,谢谢!
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: