create-config
create-config copied to clipboard
package manager (npm, yarn, etc.) is not asked in style (How would you like to use ESLint) option
Two questions (that is install the deps and what package manager) are skipped when choose to style options.
Hello @hitesh-can-code, could you please provide more details about what you mean by 'style options'?
eslint need to ask what package manager first than checking peersdeps
I couldn't reproduce this on my local machine
> bun create @eslint/config
✔ How would you like to use ESLint? · style
✔ What type of modules does your project use? · esm
✔ Which framework does your project use? · none
✔ Does your project use TypeScript? · No / Yes
✔ Where does your code run? · node
✔ How would you like to define a style for your project? · guide
✔ Which style guide do you want to follow? · standard-with-typescript
✔ What format do you want your config file to be in? · JSON
Checking peerDependencies of eslint-config-standard-with-typescript@latest
The config that you've selected requires the following dependencies:
eslint-config-standard-with-typescript@latest @typescript-eslint/eslint-plugin@^6.4.0 eslint@^8.0.1 eslint-plugin-import@^2.25.2 eslint-plugin-n@^15.0.0 || ^16.0.0 eslint-plugin-promise@^6.0.0 typescript@*
✔ Would you like to install them now? · No / Yes
? Which package manager do you want to use? …
❯ npm
yarn
pnpm
I'm getting the option to choose which package manager.
> bun --version
1.0.29
Did I miss something?
it is because you have npm installed where i only have bun
it was not using npm to install any dependencies, it was to check the package's peer dependencies: https://github.com/eslint/create-config/blob/9c4214bc879cc892fd8ba4f1259c7d0686b0d7c2/lib/init/npm-utils.js#L71-L75
for no-npm-installed envs, we could find another way to do it.