Skip to content

Commit

Permalink
Merge pull request #146 from dalenguyen/dev
Browse files Browse the repository at this point in the history
fix import link
  • Loading branch information
dalenguyen authored Oct 10, 2022
2 parents 639bc37 + 1c1a967 commit 80edd17
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 9 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@
---

## [1.3.4] - 2022-10-09

#### - :bug: [Bug Fix]

- fix import link & use commonjs

## [1.3.0] - 2022-10-09

#### - :nail_care: [Polish]
Expand Down
5 changes: 2 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
{
"name": "firestore-export-import",
"version": "1.3.0",
"version": "1.3.4",
"description": "NPM package for backup and restore Firebase Firestore",
"main": "dist/index.js",
"main": "./dist/index.js",
"types": "dist/index.d.ts",
"type": "module",
"files": [
"readme.md",
"dist/*.*.*",
Expand Down
2 changes: 1 addition & 1 deletion src/export.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import { getFirestore } from 'firebase-admin/firestore'
import { getPath, IExportOptions, traverseObjects } from './helper'
import { getPath, IExportOptions, traverseObjects } from './helper.js'

/**
* Get data from all collections
Expand Down
2 changes: 1 addition & 1 deletion src/import.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import {
parseAndConvertDates,
makeGeoPoint,
parseAndConvertGeos,
} from './helper'
} from './helper.js'

/**
* Restore data to firestore
Expand Down
6 changes: 3 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
import { cert, getApps, initializeApp } from 'firebase-admin/app';
import {getFirestore} from 'firebase-admin/firestore'
import { backupFromDocService, getAllCollectionsService, backupService } from './export';
import { IExportOptions, IImportOptions } from './helper'
import { restoreService } from './import';
import { backupFromDocService, getAllCollectionsService, backupService } from './export.js';
import { IExportOptions, IImportOptions } from './helper.js'
import { restoreService } from './import.js';

interface IInitializeAppOptions {
firestore?: FirebaseFirestore.Settings
Expand Down
2 changes: 1 addition & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"compilerOptions": {
"lib": ["es2020"],
"module": "ESNext",
"module": "CommonJS",
"noImplicitReturns": true,
"esModuleInterop": true,
"outDir": "dist",
Expand Down

0 comments on commit 80edd17

Please sign in to comment.