# valid-excel-data

> Valid data from excel table

Latest version **1.0.1** (published 2021-06-09) · MIT license · 0 weekly downloads

> **Deprecated.** This package is deprecated.

## Install

```sh
npm install valid-excel-data
pnpm add valid-excel-data
yarn add valid-excel-data
bun add valid-excel-data
```

## Health

**Score 10/100 (F)** — status: deprecated.

Negative: deprecated.

## Facts

| | |
|---|---|
| Version | 1.0.1 |
| Published | 2021-06-09 |
| First published | 2021-06-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Node | >=12 |
| Dependencies | 7 |
| Unpacked size | 53.8 KB |
| Known vulnerabilities | 0 (+7 in 2 direct dependencies) |
| Install scripts | no |
| Author | We-Ai Solutions |
| Maintainers | jesushdezmtz |

## Links

- npm: https://www.npmjs.com/package/valid-excel-data
- npm.io page: https://npm.io/package/valid-excel-data

## Dependencies (7)

- [vue](https://npm.io/package/vue.md) ^3.0.0
- [core-js](https://npm.io/package/core-js.md) ^3.6.5
- [postcss](https://npm.io/package/postcss.md) ^7.0.35
- [tailwindcss](https://npm.io/package/tailwindcss.md) npm:@tailwindcss/postcss7-compat@^2.1.4
- [autoprefixer](https://npm.io/package/autoprefixer.md) ^9.8.6
- [element-plus](https://npm.io/package/element-plus.md) ^1.0.2-beta.46
- [@tailwindcss/postcss7-compat](https://npm.io/package/@tailwindcss/postcss7-compat.md) ^2.1.4

## Recent versions

- 1.0.1 (latest) — 2021-06-09
- 1.0.0 — 2021-06-08
- 0.1.0 — 2021-06-08

## README

# valid-excel-data

Component in charge of validate the information of a excel table. The information is copied with its headers, it is validated with the headers added in the component instance, and a json is returned.

## Installation

Using npm:
```bash
npm install valid-excel-data
```
Using yarn:
```bash
yarn add valid-excel-data
```

## Example

```c
<template>
  <div>
    <ValidExcelData
      :title="title"
      :subtitle="subtitle"
      :headers="headers"
      :dataLabels="dataLabels"
      @response="YourMethod"
    />
  </div>
</template>
```

```script
import ValidExcelData from "valid-excel-data"

export default {
  components: {
    ValidExcelData,
  },
  setup() {
    const headers = [
      { header: "Product", required: true, type: "string" },
      { header: "Stock", required: true, type: "int" },
      { header: "Price", required: true, type: "float" },
      { header: "Comments ", required: false, type: "string" },
    ];
    const title = "Excel information validation";
    const subtitle = "Copy the information and press Ctrl + V to validate";

    const dataLabels = {
      headers: {
        headersValidated: "Header validated",
        headersMissing: "Headers are missing",
        headersNotRequired: "Header not required",
      },
      fields: {
        fieldEmpty: "Empty",
        invalidDataType: "Invalid data type",
      },
      button: {
        textButton: "Continue",
        headersMissing : "Headers are missing",
        invalidDataType: "Field data type invalid",
        fieldEmpty: "Field empty",
      }
    };

    const YourMethod = (json) => {
      // Response of component
      console.log(json);      
    };
},
```
## Props

| Prop| Required  | Type | Default value|
| :---:   | :-: | :-: | :-: |
| headers| True| Array | []|
| title| False| String| Validación de información Excel |
| subtitle| False| String| Copia la información y presiona Ctrl + V para validar|
| dataLabels | False| Object| Labels in spanish |

## Methods

| Method| Required  | Response|
| :---:   | :-: | :-: |
| response| True| Array |

## Author
[Wa-Ai Solutions](https://weaisolutions.com/)

## License
[MIT](https://choosealicense.com/licenses/mit/)

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