generator-bitloops 0.3.25 → 0.3.26

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/setup/index.js +13 -13
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "generator-bitloops",
3
- "version": "0.3.25",
3
+ "version": "0.3.26",
4
4
  "description": "Next.js with TypeScript, Tailwind, Storybook and Cypress generator by Bitloops",
5
5
  "license": "MIT",
6
6
  "author": "Bitloops S.A.",
package/setup/index.js CHANGED
@@ -128,7 +128,7 @@ export default class extends Generator {
128
128
  createNextAppCommand.push('--src-dir');
129
129
  createNextAppCommand.push('--import-alias');
130
130
  createNextAppCommand.push('@/*');
131
- createNextAppCommand.push('--use-npm');
131
+ createNextAppCommand.push('--use-pnpm');
132
132
  createNextAppCommand.push('--eslint');
133
133
 
134
134
  if (this.options.typescript) {
@@ -148,7 +148,7 @@ export default class extends Generator {
148
148
  exec(
149
149
  `npx ${createNextAppCommand.join(' ')} && cd ${toKebabCase(
150
150
  this.options.project,
151
- )} && npm install ${additionalPackages}`,
151
+ )} && pnpm add ${additionalPackages}`,
152
152
  ).on('exit', (code) => {
153
153
  this.destinationRoot(
154
154
  this.destinationPath(toKebabCase(this.options.project)),
@@ -207,8 +207,8 @@ export default class extends Generator {
207
207
  this.log('Storybook installed!');
208
208
  // Verifies the correct nextjs-vite framework is used
209
209
  spawnSync(
210
- 'npm',
211
- ['install', '--save-dev', '@storybook/nextjs-vite@^10'],
210
+ 'pnpm',
211
+ ['add', '-D', '@storybook/nextjs-vite@^10'],
212
212
  { stdio: 'inherit', cwd: this.destinationRoot() },
213
213
  );
214
214
  this.log('@storybook/nextjs-vite installed!');
@@ -219,17 +219,17 @@ export default class extends Generator {
219
219
  // Conditionally add Cypress
220
220
  if (this.options.cypress) {
221
221
  this.log('Installing Cypress...');
222
- spawnSync('npm', ['install', '--save-dev', 'cypress'], {
222
+ spawnSync('pnpm', ['add', '-D', 'cypress'], {
223
223
  stdio: 'inherit',
224
224
  cwd: this.destinationRoot(),
225
225
  });
226
226
  this.log('Cypress installed!');
227
227
  if (this.options.bitloops) {
228
228
  spawnSync(
229
- 'npm',
229
+ 'pnpm',
230
230
  [
231
- 'install',
232
- '--save-dev',
231
+ 'add',
232
+ '-D',
233
233
  'mochawesome',
234
234
  'mochawesome-merge',
235
235
  'mochawesome-report-generator',
@@ -245,8 +245,8 @@ export default class extends Generator {
245
245
  if (this.options.i18n) {
246
246
  this.log('Installing i18n packages...');
247
247
  spawnSync(
248
- 'npm',
249
- ['install', 'i18next', 'i18next-icu', 'react-i18next'],
248
+ 'pnpm',
249
+ ['add', 'i18next', 'i18next-icu', 'react-i18next'],
250
250
  { stdio: 'inherit', cwd: this.destinationRoot() },
251
251
  );
252
252
  this.log('i18n packages installed!');
@@ -376,7 +376,7 @@ export default class extends Generator {
376
376
  const path = 'cypress/helpers/index.ts';
377
377
  this.fs.copyTpl(this.templatePath(path), this.destinationPath(path));
378
378
  }
379
- spawnSync('npm', ['install', '--save-dev', 'react-aria-components'], {
379
+ spawnSync('pnpm', ['add', '-D', 'react-aria-components'], {
380
380
  stdio: 'inherit',
381
381
  cwd: this.destinationRoot(),
382
382
  });
@@ -445,9 +445,9 @@ export default class extends Generator {
445
445
  );
446
446
  this.log('');
447
447
  this.log('Use the following commands to start:');
448
- this.log('- `npm run dev` to start the Next.js app.');
448
+ this.log('- `pnpm dev` to start the Next.js app.');
449
449
  if (this.options.storybook)
450
- this.log('- `npm run storybook` to start Storybook.');
450
+ this.log('- `pnpm storybook` to start Storybook.');
451
451
  if (this.options.cypress)
452
452
  this.log('- `npx cypress open --e2e --browser chrome` to open Cypress.');
453
453
  if (this.options.cypress)