Skip to content

Commit

Permalink
Merge pull request #1313 from habx/fix/exceljs-dynamic-import
Browse files Browse the repository at this point in the history
APP-28603: Fix dynamic import of `exceljs` dependency
  • Loading branch information
habx-auto-merge[bot] authored Mar 30, 2022
2 parents 5ab3dda + 6618f4e commit e5bbacb
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/imex/exceljs.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import type * as Excel from 'exceljs'

const getExcelJs = () => import('exceljs')
const getExcelJs = async () => (await import('exceljs')).default

export const getCellValueTypes = async () => {
const excelJS = await getExcelJs()
Expand All @@ -10,5 +8,6 @@ export const getCellValueTypes = async () => {

export const createWorkbook = async () => {
const excelJS = await getExcelJs()
return new excelJS.Workbook() as Excel.Workbook

return new excelJS.Workbook()
}

0 comments on commit e5bbacb

Please sign in to comment.