Syntixi 1.0.18

dotnet add package Syntixi --version 1.0.18                
NuGet\Install-Package Syntixi -Version 1.0.18                
此命令旨在在 Visual Studio 的包管理器控制台内使用,因为它使用了 NuGet 模块的 Install-Package 版本。
<PackageReference Include="Syntixi" Version="1.0.18">
  <PrivateAssets>all</PrivateAssets>
  <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>                
对于支持 PackageReference 的项目,将此 XML 节点复制到项目文件中以引用包。
paket add Syntixi --version 1.0.18                
#r "nuget: Syntixi, 1.0.18"                
#r 指令可以在 F# Interactive 和 Polyglot Notebooks 中使用。将其复制到交互式工具或脚本的源代码中以引用包。
// Install Syntixi as a Cake Addin
#addin nuget:?package=Syntixi&version=1.0.18

// Install Syntixi as a Cake Tool
#tool nuget:?package=Syntixi&version=1.0.18                

Syntixi 属性

Syntixi 属性旨在将 Syncfusion 许可证密钥嵌入到您的代码中。这只是一个包含属性的包。实际生成实现在 Syntixi.SourceGenerator 包中。

入门指南

要开始使用 Syntixi 属性,您首先需要将库添加到项目中。

安装

如果您正在使用 NuGet 包管理器,您可以在包管理器控制台中运行以下命令来安装 Syntixi 属性

Install-Package Syntixi

这将添加属性包和源生成器包作为开发依赖项。

用法

要使用 Syntixi 属性,您需要在您的类中添加 EmbedSyncfusionLicenseKey 属性。这将 SYNCFUSION_LICENSE_KEY 嵌入到您的代码中。这是一个使用 WPF 的示例。

    /// <summary>
    /// WPF Application entry point.
    /// </summary>
    [Syntixi.Attributes.EmbedSyncfusionLicenseKey]
    public partial class App : Application
    {
        /// <summary>
        /// Initializes a new instance of the <see cref="App"/> class.
        /// </summary>
        public App()
        {
            Syncfusion.Licensing.SyncfusionLicenseProvider.RegisterLicense(SYNCFUSION_LICENSE_KEY);
        }
    }

然后您需要将许可证密钥添加到您的 CI/CD 管道或本地环境变量中。如果您在本地环境中工作,可能需要重新启动 IDE 或 codespace 以便拾取更改。

贡献或问题

欢迎对 Syntixi 的贡献和建议!请查看 https://github.com/dpvreony/syntixi/

许可

Syntixi 属性在 MIT 许可下发布。请参阅包中的 LICENSE 文件以获取更多信息。

此包中没有受支持的框架资产。

了解更多关于 目标框架.NET Standard 的信息。

NuGet 包

此包未被任何 NuGet 包使用。

GitHub 仓库

此包未被任何流行的 GitHub 仓库使用。

版本 下载 最后更新
1.0.18 84 6/21/2024