ASP.NET Core MVC / Razor Pages UI: JavaScript Global Features API
vcp.globalFeatures
API allows you to get the enabled features of the Global Features in the client side.
This document only explains the JavaScript API. See the Global Features document to understand the VCP Global Features system.
Usage
//Gets all enabled global features.
> vcp.globalFeatures.enabledFeatures
[ 'Shopping.Payment', 'Ecommerce.Subscription' ]
//Check the global feature is enabled
> vcp.globalFeatures.isEnabled('Ecommerce.Subscription')
true
> vcp.globalFeatures.isEnabled('My.Subscription')
false