kdg-react
v1.38.0
Published
The official KDG reusable React component library
Downloads
254
Readme
Install the package via NPM
- Install dependencies
- Use Node version 16.20.0 or later.
- Install the package
npm install kdg-react
Testing locally with npm link
- Build and package the library package with
npm run pack
- Run
npm link
in the root folder - Inside your application, run
npm link kdg-react
- Rebuild the library with
npm run pack
after making any changes
Testing and installing via .zip/.tgz
- Package the library with
npm run pack
- An exported .tgz of the current version will be created at
./pkg
to be added to your project - Add this .tgz to your application and reference it in
package.json
viafile:/path-to-file.tgz
Contributing
- Build at test your changes by following the testing steps above
- Spin up the local storybook server with
npm run dev
- Update applicable component stories at
/src/stories
- Create a PR at KDG-React
Additional Notes
Internal onclick events should be wrapped with the
handleOnClick
function located at/src/utils/Common
to ensure event bubbling and propagation is standardized (WrappedClickable/src/components/Clickable
can be substituted when a mouse event is unavailable)You may need to include the CoreUI CSS in your application
import '@coreui/coreui-pro/dist/css/coreui.min.css'