Introducing Socket Firewall: Free, Proactive Protection for Your Software Supply Chain.Learn More
Socket
Book a DemoInstallSign in
Socket

@wedgekit/global-styles

Package Overview
Dependencies
Maintainers
17
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@wedgekit/global-styles

## Purpose

latest
npmnpm
Version
2.0.0
Version published
Maintainers
17
Created
Source

GlobalStyles

Purpose

The purpose of @wedgekit/global-styles is to give all consuming apps consistent styling. (eg., a consistent scroll bar for both Windows and Mac users).

Usage

Consumers must import the global-styles package and place the component at the top of their React tree.

import styled from 'styled-components';

import { GlobalScrollbar } from '@wedgekit/global-styles';

const OverflowDiv = styled.div`
  height: 100px;
  overflow: auto;
`;

const Example = () => {
  return (
    <>
      <GlobalScrollbar />
      <OverflowDiv>
        <h1>Scroll to read the overflow content!</h1>
        <h2>The scrollbar is standardized</h2>
        <h3>Isn't that special</h3>
      </OverflowDiv>
    </>
  );
};

render(<Example />);

Styled Components

GlobalScrollbar

GlobalScrollbar is currently the only export from @wedgekit/global-styles and gives an application a consistent scrollbar for all users. However, support is non-standard and some users may face incompatibilities (https://developer.mozilla.org/en-US/docs/Web/CSS/::-webkit-scrollbar).

FAQs

Package last updated on 29 Mar 2022

Did you know?

Socket

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