setTheme

Type:Function
Status:stable
Since:1.0.0
Platform:js
@blackbyte.sugar.js.theme

This function allows you to set a theme for your website/application. It will set the theme on the body tag like theme-... and set a cookie to remember the theme.

Params

  1. theme*-String

    The theme name to set

  2. settings{}TSetThemeSettings

    Some settings to configure your theme setter

Example

import { setTheme } from '@blackbyte/sugar/theme';
setTheme('dark');

Settings

  1. cookieName’theme’String

    The cookie name to use to store the theme

Todo

  • testsnormal