@instructure/ui-scripts

8.55.0 • Public • Published

category: packages

ui-scripts

npm  MIT License  Code of Conduct

A CLI tool for InstUI build and publish tools made by Instructure Inc.

Scripts

For more documentation on available options and parameters for individual commands run:

ui-scripts <command> --help

build

To build (babel transpile) a package to be consumed as a library:

npm run ui-scripts build --modules cjs writes commonjs modules to the lib/ directory.

npm run ui-scripts build --modules es writes es modules to the es/ directory.

npm run ui-scripts build --modules es,cjs writes es modules to both directories.

If not specified, modules defaults to es.

To build (webpack) a package to be consumed as an application:

npm run ui-scripts bundle

bump version

To update all package versions (defaults to determining the version automatically using commit messages):

npm run ui-scripts bump [version|major|minor|patch]

clean

To clean out built/generated files from a package:

npm run ui-scripts clean

deprecate

Deprecates ALL of a certain version of instUI npm packages by running npm deprecate. versionToDeprecate defaults to the current version.

npm run ui-scripts deprecate --versionToDeprecate 5.11.0 --fixVersion 5.11.1

examples (Storybook)

To build component examples and start up a dev server with hot reloading:

npm run ui-scripts examples --watch -p 8080

To build component examples for deploying:

npm run ui-scripts examples

generating design tokens

npm run generate-tokens <options>

Generate cross-platform design tokens for the given theme.

npm run generate-all-tokens

Generate cross-platform design tokens for all themes in the repo.

lint

To lint (eslint/stylelint) all files:

npm run ui-scripts lint

To lint specific files:

npm run ui-scripts lint ./somefile.ts ./someotherfile.css

To fix lint issues:

npm run ui-scripts lint --fix

publish to npm

To publish all packages (defaults to current version):

npm run ui-scripts publish [version]

server

To start up a server to test production builds of examples or docs:

npm run ui-scripts server -p 8080

npm tag

To add an NPM dist-tag for all packages:

npm run ui-scripts tag add 5.11.0 latest

To remove an NPM dist-tag for all packages:

npm run ui-scripts tag rm 5.11.0 latest

running tests

To run all tests:

npm run ui-scripts test

To run tests for a package:

npm run ui-scripts test -- --scope @instructure/ui-avatar

Configuration

If you'd like to use the publish, deploy, and release scripts, you'll need to configure your project as follows:

Add a .env file to your project root or define these env vars for your shell:

NPM_TOKEN=
NPM_USERNAME=
NPM_EMAIL=

Readme

Keywords

none

Package Sidebar

Install

npm i @instructure/ui-scripts

Weekly Downloads

1,269

Version

8.55.0

License

MIT

Unpacked Size

401 kB

Total Files

141

Last publish

Collaborators

  • bpjatacsuk
  • ajmal-esa
  • razorsh4rk
  • david.wenzlick.inst
  • robinkuss64
  • ardena
  • jcflow
  • jguardadom
  • jdewar
  • xcudder
  • ericsaupe
  • joyenjoyer
  • omarpr
  • cguanzon-inst
  • sarahgerard
  • jacksonhowe
  • jakeoeding
  • camray
  • cjs118
  • matyas.szabo
  • herrtopi
  • angela.gomba
  • kyler-instructure
  • instuici
  • eschiebel
  • maths22
  • jcrystal
  • skacsmark
  • itadmins
  • quizzesuici
  • instructure-toolsmiths-service-user
  • aogata-inst
  • instout