ember-html-table-to-excel

3.2.1 • Public • Published

ember-html-table-to-excel

npm version downloads Build Status Ember Observer Score Dependency Status devDependency Status Code Climate

ember-html-table-to-excel is an addon that converts html tables to Excel documents in your Ember.js application. ember-cli-data-export-with-style is used in background.

Installation

cd your-project-directory
ember install ember-html-table-to-excel

After installing ember-cli-data-export-with-style dependency, you need to import following 4 javascript files directly from the imported addon such as:

  included: function(app) {
    this._super.included(app);
    app.import('node_modules/ember-cli-data-export-with-style/vendor/Blob.js');
    app.import('node_modules/ember-cli-data-export-with-style/vendor/FileSaver.js');
    app.import('node_modules/ember-cli-data-export-with-style/vendor/jszip.min.js');
    app.import('node_modules/ember-cli-data-export-with-style/vendor/xlsx.core.min.js');
  }

Usage

You can use as ember-html-table-to-excel-button component with tableId (and optional fileName, sheetName and headerRows (array)) parameters.

{{#ember-html-table-to-excel-button
  tableId="my-custom-html-table-id"
  fileName=fileName
  sheetName=sheetName
  headerRows=headerRows
}}
  Export to Excel
{{/ember-html-table-to-excel-button}}

Checkout live examples at ember-html-table-to-excel demo page

License

This project is licensed under the MIT License.

Package Sidebar

Install

npm i ember-html-table-to-excel

Weekly Downloads

23

Version

3.2.1

License

MIT

Unpacked Size

17 kB

Total Files

19

Last publish

Collaborators

  • ahmetemrekilinc
  • esrgrlk
  • eztaskomaz