theme
Returns the currently active theme.
The useTheme hook provides an easy way to read, update and toggle the active application theme.
import { useTheme } from "@shivms/ui";Returns the currently active theme.
Updates the current application theme.
Switches between light and dark themes.
Import the hook and use it inside your React component.
import {
Button,
useTheme,
} from "@shivms/ui";
export default function App() {
const {
theme,
toggleTheme,
} = useTheme();
return (
<Button onClick={toggleTheme}>
Current Theme: {theme}
</Button>
);
}Access the current application theme.
Change the active theme programmatically.
Switch between light and dark mode with one function.
Explore more SHIVMS UI documentation and guides.
Learn what SHIVMS UI is and how to begin.
Install the library into your project.
Reusable React hooks for state, themes and responsiveness.
Use built-in icons throughout your application.
Configure light and dark themes.
Reusable helper functions for everyday development.
Build accessible user interfaces.
Customize colors, spacing and components.
See what's new in each release.