1- import nypm from "nypm" ;
1+ import * as nypm from "nypm" ;
22import type { PackageJson } from "pkg-types" ;
33import { useContext } from "../context" ;
44import { findUp } from "./fs" ;
@@ -24,9 +24,9 @@ export async function readPackageJSON() {
2424 */
2525export async function updatePackageJSON (
2626 fn : (
27- json : PackageJson ,
27+ json : PackageJson
2828 // biome-ignore lint: lint/suspicious/noConfusingVoidType
29- ) => void | PackageJson | Promise < PackageJson | void > ,
29+ ) => void | PackageJson | Promise < PackageJson | void >
3030) {
3131 const path = await findUp ( "package.json" ) ;
3232 if ( ! path ) {
@@ -42,7 +42,7 @@ export async function updatePackageJSON(
4242 */
4343export async function addDependency (
4444 name : string | string [ ] ,
45- opts ?: nypm . OperationOptions & { log ?: boolean } ,
45+ opts ?: nypm . OperationOptions & { log ?: boolean }
4646) {
4747 const context = useContext ( ) ;
4848 if ( opts ?. log !== false ) {
@@ -65,7 +65,7 @@ export async function addDependency(
6565 */
6666export async function addDevDependency (
6767 name : string | string [ ] ,
68- opts ?: Exclude < nypm . OperationOptions , "dev" > & { log ?: boolean } ,
68+ opts ?: Exclude < nypm . OperationOptions , "dev" > & { log ?: boolean }
6969) {
7070 await addDependency ( name , { dev : true , ...opts } ) ;
7171}
@@ -77,7 +77,7 @@ export async function addDevDependency(
7777 */
7878export async function removeDependency (
7979 name : string ,
80- opts ?: nypm . OperationOptions & { log ?: boolean } ,
80+ opts ?: nypm . OperationOptions & { log ?: boolean }
8181) {
8282 const context = useContext ( ) ;
8383 if ( opts ?. log !== false ) {
0 commit comments