question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

error when i run npm run storybook

See original GitHub issue

Describe the bug After do the installation explain here https://storybook.js.org/docs/guides/guide-angular/ i tried to run my storybook but i get an error:

ERR! TypeError: Cannot destructure property options of ‘undefined’ or ‘null’. ERR! at getAngularCliWebpackConfigOptions (/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/angular-cli_config.js:70:9) ERR! at Object.webpackFinal (/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/framework-preset-angular-cli.js:14:92) ERR! at /Users/charlypy/qima-platform/front/node_modules/@storybook/core/dist/server/presets.js:74:72 ERR! at processTicksAndRejections (internal/process/task_queues.js:89:5) ERR! TypeError: Cannot destructure property options of ‘undefined’ or ‘null’. ERR! at getAngularCliWebpackConfigOptions (/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/angular-cli_config.js:70:9) ERR! at Object.webpackFinal (/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/framework-preset-angular-cli.js:14:92) ERR! at /Users/charlypy/qima-platform/front/node_modules/@storybook/core/dist/server/presets.js:74:72 ERR! at processTicksAndRejections (internal/process/task_queues.js:89:5) { ERR! stack: "TypeError: Cannot destructure property options of ‘undefined’ or " + ERR! "‘null’.\n at getAngularCliWebpackConfigOptions " + ERR! ‘(/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/angular-cli_config.js:70:9)\n’ + ERR! ’ at Object.webpackFinal ’ + ERR! ‘(/Users/charlypy/qima-platform/front/node_modules/@storybook/angular/dist/server/framework-preset-angular-cli.js:14:92)\n’ + ERR! ’ at ’ + ERR! ‘/Users/charlypy/qima-platform/front/node_modules/@storybook/core/dist/server/presets.js:74:72\n’ + ERR! ’ at processTicksAndRejections ’ + ERR! ‘(internal/process/task_queues.js:89:5)’ ERR! }

image

The project has been generated with Jhypster. I have npm v : 6.9.0, node : 12.1.0 and angular 7.2.2

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:8 (1 by maintainers)

github_iconTop GitHub Comments

4reactions
fishonwebcommented, May 27, 2019

@arjunkalburgi we fix it for our project. The undefined was build from angular.json, so we add build and options in project in our angular.json like this

 "projects": {
        "app-front": {
            "root": "",
            "sourceRoot": "src/main/webapp",
            "projectType": "application",
            "architect": {
                "build": {
                    "builder": "@angular-devkit/build-angular:browser",
                    "options": {
                        "outputPath": "build",
                        "index": "src/index.html",
                        "main": "src/main/webapp/app/app.main.ts",
                        "polyfills": "src/main/webapp/app/polyfills.ts",
                        "tsConfig": "tsconfig.json",
                        "assets": ["src/main/webapp/content"],
                        "styles": ["src/main/webapp/content/global.css"],
                        "scripts": []
                    }
                }
            }
        }
    },

Hope it will help you

0reactions
stale[bot]commented, Jul 26, 2019

Hey there, it’s me again! I am going close this issue to help our maintainers focus on the current development roadmap instead. If the issue mentioned is still a concern, please open a new ticket and mention this old one. Cheers and thanks for using Storybook!

Read more comments on GitHub >

github_iconTop Results From Across the Web

ERR! on npm run storybook · Issue #145 - GitHub
I get thesse errors: What am i doing wrong? npm run storybook npm ERR! Darwin 15.4.0 npm ERR! argv "/usr/local/Cellar/node/5.10.1/bin/node" ...
Read more >
Error running storybook - sh: 1: start-storybook: not found
This error is due to the node_modules folder. If you delete that folder and run npm install . it will work. Mostly due...
Read more >
CLI options - Storybook
If you're using npm instead of yarn to publish Storybook, the commands work slightly different. For example, npm run build-storybook -- -o ./path/to/build...
Read more >
@storybook/react-native - npm
Start using @storybook/react-native in your project by running `npm ... the error Can't resolve 'babel-loader' install babel-loader from npm ...
Read more >
npm run storybook blocked by "Cannot find module 'react ...
js" ERR! Error: Cannot find module 'react/package.json' ERR! Require stack: ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found