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

gather-content-ui

v0.53.6

Published

GatherContent UI Library

Downloads

891

Readme

[!CAUTION] This library has been deprecated in favour of @gathercontent/ui and @gathercontent/icons. No further updates will be made here.
For any local development the contents of this repo have been moved to CSR →

Content Workflow UI Component Library 🧩

TypeScript Storybook TailwindCSS NPM GitHub Actions

UI component library for all GatherContent components.

🧑‍🎨 Usage💻 Local development🎨 Code styling / linting🧑‍🔬 Testing🏗 Setting up dependencies

⌨ Useful commands🚀 How to deploy👥 Code owners🔗 Useful links

🧑‍🎨 Usage

(Back to top)

The library is available on npm.

npm install gather-content-ui

Using the components is just like any other npm module. For e.g.:

// Import the button component
import { Button } from 'gather-content-ui';

// Require once all the CSS directly from the node_modules folder
require('gather-ui/dist/styles.css');

💻 Local Development

(Back to top)

  1. Download the repository and run npm ci
  2. Make changes to the components living on the /lib folder
  3. Preview changes by running the live style guide, using npm run storybook and pointing your browser to http://localhost:6006/
  4. Watch for file changes and rebuild with npm run build:watch (useful when you link your local version of gather-ui in the app)

🎨 Code Styling and Linting

(Back to top)

We use both eslint and prettier to lint and format our code. You can run these commands to check your code;

npm run lint

If you would like to prettier to automatically fix the issues you can run:

npm run format:js

Furthermore, as we use TypeScript we also have the TypeScript compiler to check our code. You can run this command to check your code;

npm run type-check

Stylelint

We also use stylelint to be able to lint and format our CSS. You can run these commands to check your code;

npm run lint:style
npm run format:style

🧑‍🔬 How to run tests

(Back to top)

Tests live alongside the code within a .specs folder and should be ran using npm run test.

🏗 Setting up dependencies

(Back to top)

All the project dependencies are listed in the package.json file. You can install them using npm ci. NPM should have been installed when you ran through the local development in docker-base. However, if you don't have it installed run brew install node@18 to install it.

⌨ Useful commands

(Back to top)

Linking the library

You can use npm link to link your local version of this library to the node_modules in your app.

For this to work, you also need to run npm link react in this repository. Original issue here

🚀 How to deploy

(Back to top)

🧱 Building for production

To build the components to be consumed by any application, both JavaScript and CSS files need to be generated. Running npm run build will:

  1. Generate ES5 compliant versions of each component in /dist
  2. Generate a .css files containing all the concatenated component styles.
  3. Copy over Sass configuration files to the /dist folder in order to be consumed externally.

📰 Publishing

The best and easiest way to publish this library to npm is to use our GitHub action.

  1. Head on over to the actions tab
  2. Select the "publish-npm" workflow
  3. Click the "Run workflow" dropdown
  4. Select a branch (this will just be main 99.99% of the time) and a version
  5. Click "Run workflow"
  6. Sit back and relax as the robots publish it for you! 🤖

👥 Code owners

(Back to top)

@Bynder/content-workflow-frontend →

🔗 Useful links

(Back to top)

Storybook →

Related Repositories

Mono →

CSR →