Socket
Socket
Sign inDemoInstall

@rmwc/provider

Package Overview
Dependencies
Maintainers
1
Versions
163
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@rmwc/provider - npm Package Compare versions

Comparing version 14.0.4 to 14.0.5

6

package.json
{
"name": "@rmwc/provider",
"version": "14.0.4",
"version": "14.0.5",
"description": "RMWC Provider component",

@@ -36,5 +36,5 @@ "main": "./index.js",

"dependencies": {
"@rmwc/base": "14.0.4",
"@rmwc/types": "14.0.4"
"@rmwc/base": "14.0.5",
"@rmwc/types": "14.0.5"
}
}
# Provider
> A component that provides global configuration for RMWC.
A component that provides global configuration for RMWC.
- Module **@rmwc/provider**
You can wrap your top level App component with RMWC provider to set global configuration options. Just pass the options in as props.
```js
```jsx
`
import React from 'react';
import \* as ReactDOM from 'react-dom';
import * as ReactDOM from 'react-dom';
import App from './App'; // your main app component
import { RMWCProvider } from '@rmwc/provider';
// This example disables ripples globally by default
ReactDOM.render(
<RMWCProvider
// Globally disable ripples
ripple\={false}
ripple={false}
// Global options for icons
// Takes the same options as the icon component
icon\={{
icon={{
basename: 'material-icons'
}}
// Global options for typography
// allows mapping of a defaultTag or specific classes
// See the Typography docs for more info
typography\={{
typography={{
defaultTag: 'div',
headline1: 'h1'
}}
// Global options for tooltips
// Takes most of the options for tooltips
// See the Tooltip docs for more info
tooltip\={{
tooltip={{
align: 'right'
}}
\>
>
<App />
</RMWCProvider\>,
</RMWCProvider>,
document.getElementById('root'),
);
`

@@ -78,1 +51,14 @@ ```

## RMWCProvider
A provider for setting global options in RMWC.
### Props
| Name | Type | Description |
|------|------|-------------|
| `children` | `ReactNode` | Children to render |
| `icon` | `Partial<IconOptions>` | Global options for icons |
| `ripple` | `boolean` | Enable / Disable interaction ripples globally |
| `tooltip` | `Partial<TooltipOptions>` | Global tooltip options |
| `typography` | `Partial<TypographyOptions>` | Global typography options |
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