• .netcore 模块积累


    最全的 demo

    https://github.com/XiaoFaye/netcore-samples

    http://files.cnblogs.com/files/kellynic/practical-aspnetcore-master.zip

    --------------------------------

    .net core markdown 转换

    "CommonMark.Net" : "0.13.4"

    --------------------------------

    .net core 国际区域化,做多国语言版有用

    "Microsoft.AspNetCore.Localization": "1.1.0",
    "Microsoft.Extensions.Localization" : "1.1.0"

    --------------------------------

    .net core 退出程序时有用,IApplicationLifetime

    public void Configure(IApplicationBuilder app, IApplicationLifetime lifetime)
    {
    lifetime.ApplicationStarted.Register(() => System.Console.WriteLine("===== Server is starting"));
    lifetime.ApplicationStopping.Register(() => System.Console.WriteLine("===== Server is stopping"));
    lifetime.ApplicationStopped.Register(() => System.Console.WriteLine("===== Server has stopped"));

    --------------------------------

    .net core 获取平台环境信息

    "Microsoft.Extensions.PlatformAbstractions" : "1.1.0-*"

    --------------------------------

    .net core 循环 form 表单值

    var form = await context.Request.ReadFormAsync();

    for (var k in form.Keys)

    --------------------------------

    .net core 获取上传文件

    var form = await context.Request.ReadFormAsync();

    for (var f in form.Files)

    --------------------------------

    .net core 读取 xml 配置

    "Microsoft.Extensions.Configuration.Xml" : "1.1.0",

    --------------------------------

    .net core 读取 ini 配置

    "Microsoft.Extensions.Configuration.INI" : "1.1.0",

    --------------------------------

    .net core 重定向,正则

    "Microsoft.AspNetCore.Rewrite" : "1.0.0-*",

    public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory logger)
    {
    var options = new RewriteOptions()
    .AddRedirect("([/_0-9a-z-]+)+(.*)$", "/?path=$1&ext=$2"); //redirect any path that ends with .html

    app.UseRewriter(options);

    --------------------------------

    .net core 日志Serilog

    "Serilog.Extensions.Logging": "1.0.0-rc2-10110",
    "Serilog.Sinks.File": "2.0.0-rc-706"

    --------------------------------

    .net core mvc测试

    MyTested.AspNetCore.Mvc

    --------------------------------

    .netcore razor模板引擎渲染
    https://github.com/toddams/RazorLight

    --------------------------------

    .net core 图片,验证码

    https://github.com/JimBobSquarePants/ImageSharp

    https://github.com/dlemstra/Magick.NET

    --------------------------------

    .net core 二维码,linux环境下需先安装 apt-get install libgdiplus

    Gma.QrCodeNet.Encoding

  • 相关阅读:
    反射泛型方法
    Redis令牌桶限流
    laravel中间件的使用
    Laravel-权限系统
    Laravel 即时应用的一种实现方式
    laravel实现多模块
    laravel5+ElasticSearch+go-mysql-elasticsearch MySQL数据实时导入(mac)
    swoole视频直播
    开发SSO单点登录需要注意的问题
    进程、线程、协程三者之间的联系与区别
  • 原文地址:https://www.cnblogs.com/kellynic/p/6438946.html
Copyright © 2020-2023  润新知