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

@vectara/vectara-ui

v3.4.0

Published

Vectara's design system, codified as a React and Sass component library

Downloads

62

Readme

Vectara UI

This is Vectara's design system, codified as a React component library. It's intended solely for consumption by Vectara and currently it isn't available for use by anybody else. For more information see NO_LICENSE.

Usage

Import components like this:

import { VuiFlexContainer, VuiItem } from "@vectara/vectara-ui";

Import our utils like this:

import { extractCitations } from "@vectara/vectara-ui/lib/utils/citations";

To import the CSS for the components, import this stylesheet at the root level:

import "@vectara/vectara-ui/lib/styles/index";

If you are using Sass and need Vectara UI's Sass variables, you can use this import in the files that use the variables:

@import "@vectara/vectara-ui/lib/sassUtils/index";

Publishing

Publishing a new version of the package consists of three steps:

  1. Maintaining the CHANGELOG.
  2. Versioning the package.
  3. Publishing to NPM.

Maintain the CHANGELOG

As you introduce changes, record them in the CHANGELOG beneath the main section. Before you create a new version, submit a PR that updates the package.json version and moves the main content into a new section for the new version. We follow semver, so breaking changes should result in a major version bump.

Version the package

  1. Run npm version {number} to update package.json with the new version number and create a tag to track the version.
  2. Run git push origin --tags to push the new tag to the repo.
  3. Optional: Manually create a release in GitHub.

Publish to NPM

  1. Run npm run buildPackage to create the distributable files.
  2. Run npm login --scope=@vectara --registry="https://registry.npmjs.org/" to log into the registry and scope.
  3. Run npm publish --access public to publish the package to NPM.

Local development

Use npm run start to run the docs site locally and interact with the code you're developing.

To test the package locally, use npm link to consume the distributable files in a sibling project.

If you get an error regarding an "invalid hook call", you might need to use npm link to temporarily link the consumer's React dependencies to Vectara-UI's React dependencies. In this example, we're consuming Vectara-UI in Vectara-Answer:

npm link ../vectara-answer/node_modules/react ../vectara-answer/node_modules/react-dom ../vectara-answer/node_modules/react-router-dom

When you're done testing out the consumer, you can unlink these dependencies:

npm unlink ../vectara-answer/node_modules/react ../vectara-answer/node_modules/react-dom ../vectara-answer/node_modules/react-router-dom

Licensing and public use

Though the GitHub terms of service grant anybody the right to fork and look through this repository, we haven't yet licensed this code for use by anybody else. This means Vectara reserves all rights to the contents of this repository. You can't reproduce, distribute, or create derivative works from it. For more information on reserved copyright of GitHub repos, see https://choosealicense.com/no-permission/.

For more information on our lack of licensing, see NO_LICENSE.