Skip to content

Commit a257179

Browse files
committed
v0.3.6
1 parent 45ca642 commit a257179

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "generator-bitloops",
3-
"version": "0.3.5",
3+
"version": "0.3.6",
44
"description": "Next.js with TypeScript, Tailwind, Storybook and Cypress generator by Bitloops",
55
"license": "MIT",
66
"author": "Bitloops S.A.",

setup/index.js

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,9 @@ export default class extends Generator {
9797
this.installStorybook = function() {
9898
// Conditionally initialize Storybook
9999
if (this.options.storybook) {
100-
this.log("Adding Storybook...");
101-
this.spawnCommandSync('npx', ['-y', 'storybook@8.4', 'init', '--no-dev']);
100+
this.log('Installing Storybook...');
101+
this.spawnCommandSync('npx', ['-y', 'storybook@^8.4', 'init', '--no-dev']);
102+
this.log('Storybook installed!');
102103
// if (this.options.tailwind && this.options.storybook) {
103104
// Tailwind CSS specific setup for older versions of Storybook
104105
// this.spawnCommandSync('npx', ['storybook@latest', 'add', '@storybook/addon-styling-webpack']);
@@ -109,15 +110,16 @@ export default class extends Generator {
109110
this.installCypress = function() {
110111
// Conditionally add Cypress
111112
if (this.options.cypress) {
112-
this.log("Adding Cypress...");
113+
this.log('Installing Cypress...');
113114
this.spawnCommandSync('npm', ['install', '--save-dev', 'cypress']);
115+
this.log('Cypress installed!');
114116
}
115117
}
116118

117119
this.patchFiles = async function() {
118120
// Conditionally initialize Storybook
119121
if (this.options.storybook) {
120-
this.log("Making Storybook changes...");
122+
this.log('Making Storybook changes...');
121123
if (this.options.tailwind) {
122124
fs.unlinkSync(this.destinationPath('.storybook/preview.ts'));
123125
this.log('Setting up Tailwind CSS with Storybook...');
@@ -211,11 +213,8 @@ export default class extends Generator {
211213

212214
async main() {
213215
await this.installNextJS();
214-
this.log('Installing Storybook');
215216
this.installStorybook();
216-
this.log('Installing Cypress');
217217
this.installCypress();
218-
this.log('Patching files');
219218
await this.patchFiles();
220219
if (this.options.git) {
221220
await this.commitChanges();

0 commit comments

Comments
 (0)