CoreFlex.Razor.JsInterop
0.1.3
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package CoreFlex.Razor.JsInterop --version 0.1.3
NuGet\Install-Package CoreFlex.Razor.JsInterop -Version 0.1.3
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="CoreFlex.Razor.JsInterop" Version="0.1.3" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add CoreFlex.Razor.JsInterop --version 0.1.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: CoreFlex.Razor.JsInterop, 0.1.3"
#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 CoreFlex.Razor.JsInterop as a Cake Addin #addin nuget:?package=CoreFlex.Razor.JsInterop&version=0.1.3 // Install CoreFlex.Razor.JsInterop as a Cake Tool #tool nuget:?package=CoreFlex.Razor.JsInterop&version=0.1.3
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Core Flex JS 工具模块
提供系统常用的JS互操作的封装,便于使用。
使用
添加CoreFlexRazorJsInteropModule
模块依赖
封装Api
CookieJsInterop
提供:
GetAllCookiesAsync
获取所有CookieAddCookieAsync
添加Cookie`
LocalStorageJsInterop
提供:
SetLocalStorageAsync
: 设置LocalStorage的值GetLocalStorageAsync
: 获取LocalStorage的值RemoveLocalStorageAsync
: 移除LocalStorage的值RemovesLocalStorageAsync
: 批量删除Key的LocalStorageClearLocalStorageAsync
: 清空LocalStorage的值IsLocalStorageSupportedAsync
: 判断浏览器是否支持LocalStorageGetLocalStorageKeysAsync
: 获取LocalStorage的所有KeyContainKeyAsync
: 判断sessionStorage中是否存在某个key
SessionStorageJsInterop
提供:
SetSessionStorageAsync
: 设置SessionStorage的值GetSessionStorageAsync
: 获取SessionStorage的值RemoveSessionStorageAsync
: 移除SessionStorage的值RemovesSessionStorageAsync
: 批量删除Key的SessionStorageClearSessionStorageAsync
: 清空SessionStorage的值GetSessionStorageLengthAsync
: 获取 sessionStorage 中值的数量ContainKeyAsync
: 判断 sessionStorage 中是否含有某个键名
WindowJsInterop
提供以下功能:
CreateBlobURLAsync
: 使用 blob 创建 Blob UrlCreateBlobURLFromUint8ArrayAsync
: 使用 byte[] 创建一个 Blob 对象URLCreateBlobURLFromStringAsync
: 使用 Base64 创建一个 Blob 对象的URLRevokeUrlAsync
: 释放 Blob 对象的 URLRevokeUrlsAsync
: 批量释放 Blob 对象的 URLGetScrollPositionAsync
: 获取滚动条位置SetScrollPositionAsync
: 修改滚动条位置GetScrollHeightAsync
: 获取滚动条高度ScrollToBottomAsync
: 滚动到底部ScrollToTopAsync
: 滚动到顶部CopyToClipboardAsync
: 复制到剪贴板PlayTextAsync
: 播放文本PauseSpeechAsync
: 暂停播放语音ResumeSpeechAsync
: 继续语音播放StopSpeechAsync
: 停止语音播放EnterFullscreenAsync
: 进入全屏模式ExitFullscreenAsync
: 退出全屏模式IsFullscreenAsync
: 判断当前是否处于全屏模式ToggleFullscreenAsync
: 切换全屏模式PickContactAsync
: 使用 Contact Picker API 选择联系人GetLocationAsync
: 获取当前locationSetLocationHrefAsync
: 设置当前location hrefGoBackAsync
: 返回上一页
DocumentJsInterop
提供以下功能:
ClickDocumentAsync
: 触发点击事件ClickElementAsync
: 触发元素点击事件GetElementByIdAsync
: 获取元素HasElementByIdAsync
: 判断是否存在某个元素
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net6.0 is compatible. 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 is compatible. 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 is compatible. 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. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
net6.0
- CoreFlex.Module (>= 0.1.3)
- Microsoft.AspNetCore.Components.Web (>= 6.0.0)
-
net7.0
- CoreFlex.Module (>= 0.1.3)
- Microsoft.AspNetCore.Components.Web (>= 7.0.0)
-
net8.0
- CoreFlex.Module (>= 0.1.3)
- Microsoft.AspNetCore.Components.Web (>= 8.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.