# model-explorer

> Bento UI Building Blocks is a NPM library in an attempt to reuse the shared UI components across NCI data commons frameworks.

Latest version **0.0.64** (published 2022-10-19) · 0 weekly downloads

## Install

```sh
npm install model-explorer
pnpm add model-explorer
yarn add model-explorer
bun add model-explorer
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; large bundle; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.64 |
| Published | 2022-10-19 |
| First published | 2022-04-28 |
| Weekly downloads | 0 |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 65 |
| Unpacked size | 18.9 MB |
| Known vulnerabilities | 0 (+26 in 2 direct dependencies) |
| Install scripts | no |
| Maintainers | ambarrana |

## Links

- npm: https://www.npmjs.com/package/model-explorer
- npm.io page: https://npm.io/package/model-explorer

## Dependencies (65)

- [uuid](https://npm.io/package/uuid.md) ^8.3.1
- [axios](https://npm.io/package/axios.md) ^0.19.2
- [react](https://npm.io/package/react.md) >=16.8.0
- [redux](https://npm.io/package/redux.md) ^4.0.4
- [lodash](https://npm.io/package/lodash.md) ^4.17.20
- [rimraf](https://npm.io/package/rimraf.md) ^2.6.3
- [viz.js](https://npm.io/package/viz.js.md) 2.0.0
- [d3-ease](https://npm.io/package/d3-ease.md) ^1.0.5
- [d3-zoom](https://npm.io/package/d3-zoom.md) ^1.7.3
- [fuse.js](https://npm.io/package/fuse.js.md) ^6.6.2
- [js-yaml](https://npm.io/package/js-yaml.md) ^3.13.1
- [d3-array](https://npm.io/package/d3-array.md) ^1.2.0
- [d3-force](https://npm.io/package/d3-force.md) ^1.1.0
- [d3-scale](https://npm.io/package/d3-scale.md) ^1.0.7
- [cross-env](https://npm.io/package/cross-env.md) ^7.0.2
- [react-dom](https://npm.io/package/react-dom.md) >=16.8.0
- [react-jss](https://npm.io/package/react-jss.md) ^10.1.1
- [react-vis](https://npm.io/package/react-vis.md) ^1.11.7
- [@babel/cli](https://npm.io/package/@babel/cli.md) ^7.10.5
- [classnames](https://npm.io/package/classnames.md) ^2.2.6
- [file-saver](https://npm.io/package/file-saver.md) ^2.0.5
- [link-react](https://npm.io/package/link-react.md) ^3.0.0
- [lodash.get](https://npm.io/package/lodash.get.md) ^4.4.2
- [prop-types](https://npm.io/package/prop-types.md) ^15.7.2
- [underscore](https://npm.io/package/underscore.md) ^1.13.3
- [lodash.find](https://npm.io/package/lodash.find.md) ^4.6.0
- [react-redux](https://npm.io/package/react-redux.md) ^7.2.1
- [redux-thunk](https://npm.io/package/redux-thunk.md) ^2.3.0
- [d3-selection](https://npm.io/package/d3-selection.md) ^1.1.0
- [lodash.merge](https://npm.io/package/lodash.merge.md) ^4.6.2
- [redux-logger](https://npm.io/package/redux-logger.md) ^3.0.6
- [d3-transition](https://npm.io/package/d3-transition.md) ^1.1.3
- [react-scripts](https://npm.io/package/react-scripts.md) 3.4.1
- [@apollo/client](https://npm.io/package/@apollo/client.md) ^3.3.4
- [lodash.isequal](https://npm.io/package/lodash.isequal.md) ^4.5.0
- [lodash.memoize](https://npm.io/package/lodash.memoize.md) ^4.1.2
- [react-markdown](https://npm.io/package/react-markdown.md) ^8.0.3
- [react-to-print](https://npm.io/package/react-to-print.md) ^2.8.0
- [svg-url-loader](https://npm.io/package/svg-url-loader.md) ^5.0.0
- [lodash.debounce](https://npm.io/package/lodash.debounce.md) ^4.0.8
- [@material-ui/lab](https://npm.io/package/@material-ui/lab.md) *
- [bento-components](https://npm.io/package/bento-components.md) ^0.1.106
- [lodash.clonedeep](https://npm.io/package/lodash.clonedeep.md) ^4.5.0
- [react-router-dom](https://npm.io/package/react-router-dom.md) ^5.2.0
- [react-svg-loader](https://npm.io/package/react-svg-loader.md) ^3.0.3
- [@babel/preset-env](https://npm.io/package/@babel/preset-env.md) ^7.11.0
- [@material-ui/core](https://npm.io/package/@material-ui/core.md) >=4.0.0
- [lodash.assignwith](https://npm.io/package/lodash.assignwith.md) ^4.2.0
- [string-similarity](https://npm.io/package/string-similarity.md) ^4.0.4
- [styled-components](https://npm.io/package/styled-components.md) ^5.3.5
- [@gen3/ui-component](https://npm.io/package/@gen3/ui-component.md) ^0.5.1
- [@material-ui/icons](https://npm.io/package/@material-ui/icons.md) >=4.0.0
- [lodash.isundefined](https://npm.io/package/lodash.isundefined.md) ^3.0.1
- [@babel/preset-react](https://npm.io/package/@babel/preset-react.md) ^7.10.4
- [@react-pdf/renderer](https://npm.io/package/@react-pdf/renderer.md) ^2.0.21
- [eslint-plugin-babel](https://npm.io/package/eslint-plugin-babel.md) ^5.3.1
- [react-zoom-pan-pinch](https://npm.io/package/react-zoom-pan-pinch.md) ^1.6.1
- [@material-ui/data-grid](https://npm.io/package/@material-ui/data-grid.md) *
- [@storybook/addon-knobs](https://npm.io/package/@storybook/addon-knobs.md) ^6.3.1
- [@testing-library/react](https://npm.io/package/@testing-library/react.md) ^9.3.2
- [babel-preset-react-app](https://npm.io/package/babel-preset-react-app.md) ^10.0.1
- [@apollo/react-components](https://npm.io/package/@apollo/react-components.md) ^4.0.0
- [@testing-library/jest-dom](https://npm.io/package/@testing-library/jest-dom.md) ^4.2.4
- [@testing-library/user-event](https://npm.io/package/@testing-library/user-event.md) ^7.1.2
- [@babel/plugin-proposal-class-properties](https://npm.io/package/@babel/plugin-proposal-class-properties.md) ^7.10.4

## Recent versions

- 0.0.64 (latest) — 2022-10-19
- 0.0.63 — 2022-10-18
- 0.0.62 — 2022-10-17
- 0.0.61 — 2022-10-17
- 0.0.60 — 2022-10-12
- 0.0.59 — 2022-09-23
- 0.0.58 — 2022-09-20
- 0.0.57 — 2022-09-14
- 0.0.56 — 2022-09-14
- 0.0.55 — 2022-09-13
- 0.0.54 — 2022-08-31
- 0.0.53 — 2022-08-25
- 0.0.52 — 2022-08-25
- 0.0.51 — 2022-08-24
- 0.0.50 — 2022-08-18
- … 49 more at https://npm.io/package/model-explorer/versions

## README

# Bento UI Building Blocks

Bento UI Building Blocks is a NPM library in an attempt to reuse the shared UI components across NCI data commons frameworks.

## Installation

Use the package manager [npm](https://www.npmjs.com/) to install Bento UI Building Blocks.

```bash
npm install model-explorer
```

## Usage

### redux configuration
``` store
import { createStore, applyMiddleware, combineReducers } from 'redux';
import ReduxThunk from 'redux-thunk';
import { createLogger } from 'redux-logger';
import { ddgraph, moduleReducers as submission, versionInfo } from 'model-explorer';
import layout from '../components/Layout/LayoutState';
import stats from '../components/Stats/StatsState';

const reducers = {
  ddgraph,
  versionInfo,
  submission,
  layout,
  stats,
};

const loggerMiddleware = createLogger();

const store = createStore(
  combineReducers(reducers),
  applyMiddleware(ReduxThunk, loggerMiddleware),
);

store.injectReducer = (key, reducer) => {
  reducers[key] = reducer;
  store.replaceReducer(combineReducers(reducers));
};

export default store;
```
### Create ModelExplorer component
```react
import React from 'react';
import { ReduxDataDictionary, getModelExploreData } from 'model-explorer';
import store from '../../store';

async function getData() {
  const response = await getModelExploreData();
  Promise.all(
    [
      store.dispatch({
        type: 'RECEIVE_DICTIONARY',
        payload: { data: response.data },
      }),
      store.dispatch({
        type: 'RECEIVE_VERSION_INFO',
        data: response.version,
      }),
    ],
  );
}

const ModelExplorer = () => {
  getData();
  return (
    <ReduxDataDictionary />
  );
};

export default ModelExplorer;
```

## Scripts Available

```
### `npm run storybook`

Runs the app in the development mode.
Open [http://localhost:9001](http://localhost:9001) to view it in the browser.

The page will reload if you make edits.<br />
You will also see any lint errors in the console.
```
```
### `npm run storybook`

Builds the app for production to the `lib`  and  `es` folder.<br />
It correctly bundles React in production mode and optimizes the build for the best performance.

Your app is ready to be deployed!

```

---
_Source: https://npm.io/package/model-explorer · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
