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 🙏

© 2024 – Pkg Stats / Ryan Hefner

klarna-ui-fork

v9.3.7

Published

Klarna's UI Components

Downloads

5

Readme

Klarna UI Components

Build Status npm version

This library contains the basic set of components used by multiple front end projects across Klarna. It exposes React API compatible components as well as CSS modules.

Install

npm install @klarna/ui --save

You can use the UI components either with React and Preact. Learn more in the docs.

This project has several peer dependencies that it needs to work. Although they are no technically peer dependencies, we need to treat them that way to ensure that Webpack does not bundle them twice in the final builds of the consumer projects.

Install all peer dependencies with:

npm install prop-types react react-motion html2react ramda --save

This package has a build, but usage of it is not recommended. You must have a Babel pipeline to use it. Read more about how to config it.

Wiki

There are plenty of articles in our wiki. Check it out

Run locally

To run the project, NPM 3+ is required.

To run the showroom locally:

npm install
npm start

Open localhost:7777/ui/.

License

Please check the LICENSE file.

Contributing

Make sure:

  1. Your contribution is aligned with the styleguide.
  2. Your contribution doesn't break the grid. To avoid that, always use the $grid variable to define your sizes, as in line-height: ($grid * 4). As a rule of thumb, if your element total height (sum of content, paddings, margins, etc.) has an integer multiple of $grid you should be good.
  3. Your code is linted: npm run lint.
  4. It works in the major browsers, the simplest way is to spawn ngrok and use the cloud service of your choice. Else, you can download IE virtual machines for VirtualBox using curl -s https://raw.githubusercontent.com/xdissent/ievms/master/ievms.sh | env IEVMS_VERSIONS="9" bash.

Then:

  1. Send a PR.
  2. Once approved (with 👍 reaction or a LGTM comment):
  3. Merge to master
  4. Pull master locally
  5. Update the version using npm version <major|minor|patch> -m "Some message describing what happened" (tag will have v prefix). The message will be published as the release notes in Github.
  6. Push master and the new tag as well. (git push origin master --follow-tags)
  7. Go to https://github.com/klarna/ui/releases, click on "Draft a new release" and add notes for your release version. Make sure to enter the number of your release including the v in the "Tag version" field, ie. v4.13.2

Travis will take care of publishing your new version to npm. In a matter of minutes it should be ready. You can check the status of the release publication by reading the log of the build corresponding to your tag. The list of Travis builds can be found in https://travis-ci.org/klarna/ui/builds