The shared components for TACC WMA Workspace Portals & Websites
- Related Repositories
- Project Architecture
- Prerequisites
- Getting Started
- Developing
- Contributing
- Testing
- Core Styles, the shared UI pattern code for TACC WMA CMS Websites
directory | contents |
---|---|
src/lib |
components, tests, stories |
-
Install with any package manager e.g.
npm install @tacc/core-styles
yarn add @tacc/core-styles
-
Import component(s) e.g.
import { Button } from '@tacc/core-components';
import { FormikInput, FormikTextarea, FormikCheck, } from '@tacc/core-components';
-
Use component(s)…
Sorry. Examples are limited and incomplete:
The components are React components that should be written in TypeScript.
-
Enter the Repository Clone:
cd Core-Components
-
Install Dependencies:
npm install --include=optional
-
Start demo:
npm start
For more commands, see Commands.
- Fix it.
- Update story (as relevant).
- Update tests (as relevant).
-
Create or Improve a common component from a TACC repository e.g.
-
Put your work in a branch in this repository.
-
Open a Pull Request.
- Create a story to demo the component.
- Create unit tests.
task | reference |
---|---|
add/edit component | https://storybook.js.org/docs/writing-stories |
change interaction | https://storybook.js.org/docs/essentials/controls |
Run npm test
to execute the unit tests via Vitest.
Perform manually by installing and testing the components in a separate respository. See different approaches to testing your own packages.
command | task | service |
---|---|---|
npm run start |
start demo | Storybook |
npm run build |
build components | Vite |
npm run test |
execute unit tests | Vitest |