Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@blaze/toggles

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@blaze/toggles - npm Package Compare versions

Comparing version 0.2.0 to 0.2.1

11

CHANGELOG.md

@@ -6,7 +6,14 @@ # Change Log

## [0.2.1](https://github.com/BlazeUI/blaze/compare/@blaze/toggles@0.2.0...@blaze/toggles@0.2.1) (2018-12-19)
**Note:** Version bump only for package @blaze/toggles
# 0.2.0 (2018-12-19)
### Features
* **feature toggles:** new feature toggles package ([eb4a9a8](https://github.com/BlazeUI/blaze/commit/eb4a9a8))
- **feature toggles:** new feature toggles package ([eb4a9a8](https://github.com/BlazeUI/blaze/commit/eb4a9a8))

4

package.json
{
"name": "@blaze/toggles",
"version": "0.2.0",
"version": "0.2.1",
"description": "Open Source UI Toolkit - Feature Toggles",

@@ -43,3 +43,3 @@ "module": "dist/esm/index.js",

"homepage": "https://www.blazeui.com",
"gitHead": "7911d514a93eb46064107db84562b9d2d6fcc10d"
"gitHead": "b2e5a8daba57d012e62c5f596cb94caa08d1324f"
}

@@ -37,4 +37,17 @@ # <a href="https://blaze-toggles.firebaseapp.com">Blaze Feature Toggles</a>

Config _values_ can be either `booleans` or `strings` or `functions` that return boolean or strings. `Promises` are supported too.You can even have a promise that returns a function that returns a boolean and it'll still work!
Config _values_ can be either `booleans`, `strings` or `functions`.
`Promises` are supported.
e.g. the below to toggle the feature after 2 seconds once the promise has resolved.
```js
FeatureToggles.set({
welcomeMessage: true,
loginPage: {
rememberMe: () => new Promise((resolve) => setTimeout(() => resolve('alpha'y), 2000)),
},
});
```
### HTML

@@ -44,13 +57,11 @@

<feature-toggle feature="welcomeMessage">
<!-- content will be VISIBLE -->
content will be VISIBLE
</feature-toggle>
...
<feature-toggle feature="loginPage.rememberMe" variant="alpha">
<!-- content will be HIDDEN -->
content will be VISIBLE
</feature-toggle>
...
<feature-toggle feature="loginPage.rememberMe" variant="beta">
<!-- content will be HIDDEN -->
content will be HIDDEN
</feature-toggle>

@@ -57,0 +68,0 @@ ```

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc