npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

t2-core-react-components

v0.1.11

Published

This project is based on the [Storybook design system](https://github.com/storybookjs/design-system/).

Readme

tele2-core-react-components

This project is based on the Storybook design system.

Learn more at Learn Storybook.

If you want to use these core components in your React app

First, you can have a look at what this React sub-lib provides:

  • npm install
  • npm start

If you like what you see, and want to use one of those components in your app:

  1. Make sure that your application loads the Tele2 Core style library. For example:

    • Your application's package.json imports the tele2-core-styles NPM package, as a runtime dependency.
    • Your application has @import "~tele2-core-styles/main.css"; somewhere near the top.
  2. You are now ready to import components from this React sub-lib:

    • When you find an example that you like (such as "Simple datepicker", open the corresponding example code (demo/datepicker/examples/SimpleDatepicker.js) and copy/paste it in your app.
    • Some import declarations will have the wrong path. You'll need to fix them.

If you want to add a component to this library

Before you get started, ask yourself this fundamental question: Can this component be implemented purely in CSS? If yes, do it in the superior Tele2 Core style library. It will be more widely used, and for longer, than if the component is written here in the React sub-lib. Once you have determined that you cannot do without JS:

Getting started:

  • npm install
  • npm start
  • In another terminal, run npm run compile-less-watch

LESS

Although Create React App supports Sass (the best CSS preprocessor around!), it doesn't support LESS. This limitation is solved by running npm run compile-less-watch in the background (just like for the style library).

Adding a component

Take example on the datepicker component. All its JS and LESS code lies inside the core-components/datepicker folder. The demo code explaining how to use the component lies under demo/datepicker.

Your component may have variants. For example, datepicker has two variants: SingleDatepicker and DateRangepicker. These two variants have very similar HTML markup, and therefore the style is written in a single LESS file. If you have two variants with significant differences in their markup, it probably means they should be two different components.

To sum up:

  • Create a subdirectory inside src/core-components
  • Add one LESS file for your component
  • Add one or more

ESLint

Every time you modify the ESLint rule overrides (defined in package.json), you have to run npm clean-install for that change to be taken into account. It took me several hours to figure this out.