-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot find type definition file for 'webpack-env' #7855
Comments
This hasn't been fixed in |
To fix install types for webpack by;
After looking at the These types did not get included by the ng cli tool when creating a project. |
Nevermind the above did not fix anything. What I did that seemed like it fixed it was commenting out that reference in line 2 of |
@shilman is it going to be fixed on any RC? |
@VladislavLobakh PRs welcome. It's too late for 5.3 but I can merge it into 5.3 right after 5.2 goes live. |
@shilman it's a critical issue because we can't run it on Angular 8 :( |
@VladislavLobakh No I'm not familiar with angular. Can you fix it? |
Can confirm this. @VladislavLobakh If you can, use Edit Another workaround is installing the types for I try to figure out what's wrong later this week Example {
"extends": "../tsconfig.app.json",
"compilerOptions": {
"types": [
"node"
],
"skipLibCheck": true
},
"exclude": [
"../src/test.ts",
"../src/**/*.spec.ts",
"../projects/**/*.spec.ts"
],
"include": [
"../src/**/*",
"../projects/**/*"
],
"files": [
"./typings.d.ts"
]
} |
I was looking into this issue and found that
I don't know why this is getting added to the prod build. I haven't found anything related in That said, there's another workaround: |
w00t!! I just released https://github.com/storybookjs/storybook/releases/tag/v5.2.0-rc.10 containing PR #8036 that references this issue. Upgrade today to try it out! You can find this prerelease on the Closing this issue. Please re-open if you think there's still more to do. |
@shilman do you have any ideas about it? I'm running the story book, but it's in the console of the browser. As I understand it doesn't work with angular cli 8.3.x (according to #7877) |
@VladislavLobakh that's a separate issue, and I believe @kroeder (who solved this issue) is working on that now. |
Hey @shilman, we are in the process of upgrading from 5.1.1 to 5.2.1 and we are still seeing this issue (and then some):
For context, here is everything related to storybook in our "@storybook/addon-a11y": "5.2.1",
"@storybook/addon-actions": "5.2.1",
"@storybook/addon-knobs": "5.2.1",
"@storybook/addon-notes": "5.2.1",
"@storybook/addons": "5.2.1",
"@storybook/node-logger": "5.2.1",
"@storybook/react": "5.2.1",
"@storybook/theming": "5.2.1", And we run it with: "storybook": "start-storybook --config-dir storybook --port 9001 --static-dir .", All the errors above disappear when re-adding If that's any useful, here is our {
"compilerOptions": {
"target": "es6",
"lib": ["dom", "es2015", "es2017", "esnext.asynciterable"],
"jsx": "react",
"declaration": true,
"preserveWatchOutput": true,
"strict": true,
"noUnusedLocals": true,
"noUnusedParameters": true,
"noImplicitReturns": true,
"noFallthroughCasesInSwitch": true,
"moduleResolution": "node",
"allowSyntheticDefaultImports": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"baseUrl": "./",
"paths": {
"react": ["node_modules/@types/react"]
},
"outDir": "../storybook_dist",
"skipLibCheck": true
}
} Any idea how to fix this? |
I saw that a lot of packages added webpack env to the types property of tsconfig.json I was able get rid of it in angular but I'm not sure why it was added in the first place. If this is a trouble maker we can try to get rid of this again. Or add an explicit dependency on webpack-env in storybook/core |
This would be wonderful, thanks in advance! |
I just updated to 5.2.1 and now I have the following errors:
Is there any news about this issue? The For now I think we need to go back to the pervious stable version until a fix for this is ready. UPDATE: |
I'll release a patch PR later today that will hopefully fix some if not all of these issues. |
@robaxelsen it's been patched, available in the latest 5.2.x! |
@shilman, I can confirm that part of this got fixed (the
Any further idea? |
@kroeder @ndelangen Thoughts on typedefs for |
Great, thank you so much 😍 |
I can confirm that this fixed the issue also for a stencil project with storybook. |
Hey @shilman, any further thoughts on this? |
@astorije sorry typescript newb here. hoping @ndelangen @kroeder @gaetanmaisse can help you out |
I'm getting this error using the following packages
Running |
@cloakedninjas can you try removing node_modules & reinstalling? possibly regenerating lock files? |
No joy |
Can confirm that it's dependency in @ndelangen @kroeder @gaetanmaisse can we add this? |
I think I will go through all libs and try to remove this where it's useless and add |
I hope this one, #9536, will fix this |
Whoopee!! I just released https://github.com/storybookjs/storybook/releases/tag/v5.3.7 containing PR #9538 that references this issue. Upgrade today to try it out! Closing this issue. Please re-open if you think there's still more to do. |
Reopening this issue, it should/will 🤞 be fixed by #9536. |
Just checked and sadly 5.3.7 hasn't fixed it, still seeing those reference errors in
|
@cloakedninjas @shilman do you plan to publish a |
@gaetanmaisse Yes, in the day hopefully. |
¡Ay Caramba!! I just released https://github.com/storybookjs/storybook/releases/tag/v5.3.8 containing PR #9536 that references this issue. Upgrade today to try it out! Closing this issue. Please re-open if you think there's still more to do. |
note that the |
I now have this problem after upgrading to 5.3.19, with
|
Describe the bug
Just importing addParameters into my story causes the build to break. It does not launch when you run
yarn storybook
ornpm run storybook
** Error **
To Reproduce
Steps to reproduce the behavior:
Expected behavior
Works...
Code snippets
System:
Additional context
I had to install the @next cli, because of a different bug in Angular and Storybook.
Dev Dependencies
The text was updated successfully, but these errors were encountered: