1.0.8 • Published 5 years ago

excel-reader v1.0.8

Weekly downloads
45
License
-
Repository
-
Last release
5 years ago

#Excel-reader This is an angular module compatible with angular 6+ versions. It reads excel files, validate it, and show it in a tabular format.

#DEMO https://stackblitz.com/edit/angular-5dwch5

##Dependencies 1."xlsx":0.10.0 2."material-design-lite":^1.3.0

##Installation Run the command npm i excel-reader In your app.module.ts import the module as import {ExcelReaderModule} from "excel-reader" Add the module to the import section

imports: [
    BrowserModule,
    ExcelReaderModule
    .....
    
  ],

In your app.html put the code given below

<lib-excel-reader [xlConfig]="configXl"></lib-excel-reader>

Finally in your app.component.ts file add the configuration you want

this.configXl =
  {
    startingRow: 0,
    validation: [{
      fieldName: "work email",
      validationType: "email"
    },
    {
      fieldName: "personal email",
      validationType: "email"
    },
    {
      fieldName: "home phone",
      validationType: "number",
      length: 10
    }],
    showAll: true
  };

##Configuration Properties

  • startingRow holds the row number from which your excel sheet starts ( Not the headers and all)
  • fieldName is the name the header field in your excel sheet you want to validate
  • validationType is the type of validation you want to apply in the particular field of your excel-sheet
  • if showAll is set to true it will display all the data in the excel sheet otherwise it will only show the rows having errors. Thats all, now you can run your application and test it.
1.0.8

5 years ago

1.0.7

5 years ago

1.0.6

5 years ago

1.0.5

5 years ago

1.0.4

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

0.0.6

5 years ago

0.0.5

5 years ago

0.0.4

5 years ago

0.0.3

5 years ago

0.0.2

5 years ago

0.0.1

5 years ago