Socket
Socket
Sign inDemoInstall

mantine-json-view

Package Overview
Dependencies
37
Maintainers
1
Versions
14
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    mantine-json-view

## Install


Version published
Maintainers
1
Install size
19.0 kB
Created

Readme

Source

Mantine JSON View

Install

Mantine JSON View depends on @mantine/core, so make sure to install that dependency as well.

npm
npm install --save @mantine/core mantine-json-view
pnpm
pnpm install --save @mantine/core mantine-json-view

Usage

import { JsonView } from 'mantine-json-view';

function GettingStarted() {
  return (
    <JsonView
      // optional component for collapse icon(s)
      collapseComponent={({ collapsed, setCollapsed }) => (
        <YourCollapseComponents />
      )}
      // optional component for rendering a clipboard icon for copy/paste
      clipboardComponent={({ value }) => <YourClipboardComponent />}
      json="JSON_STRING"
      // syntax highlighting/theming
      theme={{
        colors: {
          key: theme.colors.gray[8],
          literals: {
            boolean: theme.colors.teal[6],
            number: theme.colors.blue[6],
            string: theme.colors.red[6],
            null: theme.colors.orange[9],
          },
        },
        fontFamily: 'monospace',
      }}
    />
  );
}

FAQs

Last updated on 24 Nov 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc