Skip to content

Commit bf25002

Browse files
committed
Fix lint error
1 parent b75f7fa commit bf25002

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

src/index.js

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,22 @@
11
import { Command } from 'commander';
22
import path from 'path';
3+
import fs from 'fs';
34
import chalk from 'chalk';
45
import { detectReactNativeProject, loadProjectConfiguration } from './utils/detection.js';
56
import { resolveFilePaths } from './utils/files.js';
6-
import { handleUserCancellation, displayResults, showNextSteps } from './utils/ui.js';
7+
import { parsePackageJsonVersion, updatePackageJsonVersion } from './utils/packageJson.js';
78
import { updateAndroidVersions } from './utils/android.js';
89
import { updateIOSVersions } from './utils/ios.js';
9-
import { updatePackageJsonVersion, parsePackageJsonVersion } from './utils/packageJson.js';
10+
import { handleUserCancellation, displayResults, showNextSteps } from './utils/ui.js';
1011
import {
1112
promptForPlatformSelection,
1213
promptForIncrementType,
1314
promptForConfirmation,
1415
} from './utils/prompts.js';
15-
import packageJson from '../package.json' with { type: 'json' };
16+
17+
// Load package.json
18+
const packageJsonPath = new URL('../package.json', import.meta.url);
19+
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, 'utf8'));
1620

1721
const program = new Command();
1822

0 commit comments

Comments
 (0)