Skip to content
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

[addon] addon-actions is not working v6.0.21 #104

Closed
JeffGuKang opened this issue Sep 9, 2020 · 16 comments
Closed

[addon] addon-actions is not working v6.0.21 #104

JeffGuKang opened this issue Sep 9, 2020 · 16 comments

Comments

@JeffGuKang
Copy link
Contributor

Describe the bug
A clear and concise description of what the bug is.
crypto.getRandomValues() not supported error in debug mode.

Related issue: uuidjs/uuid#416
Solution: https://github.com/uuidjs/uuid#getrandomvalues-not-supported

To Reproduce

  1. Use action addon
  2. trigger action addon
  3. boom

Expected behavior
no error

Screenshots
If applicable, add screenshots to help explain your problem.
image

Code snippets
If applicable, add code samples to help explain your problem.

import {action} from '@storybook/addon-actions'

...
<Button onPress={action('onPress')} />

System:
No related

Additional context

@JeffGuKang JeffGuKang changed the title [addon] action error with React Native with simulators [addon] action error in React Native simulators Sep 9, 2020
@JeffGuKang
Copy link
Contributor Author

JeffGuKang commented Sep 9, 2020

And I just checked 5.3.21. It is working perfectly. Just use 5.3.21 instead latest version.

@shilman shilman transferred this issue from storybookjs/storybook Sep 9, 2020
@nidheeshdas
Copy link

I'm facing same issue on a fresh Expo with just sb init. No other code changes.

{
"dependencies": {
    "expo": "~38.0.8",
    "expo-status-bar": "^1.0.2",
    "react": "~16.11.0",
    "react-dom": "~16.11.0",
    "react-native": "https://github.com/expo/react-native/archive/sdk-38.0.2.tar.gz",
    "react-native-web": "~0.11.7"
  },
  "devDependencies": {
    "@babel/core": "^7.8.6",
    "@storybook/addon-actions": "^6.0.21",
    "@storybook/addon-essentials": "^6.0.21",
    "@storybook/addon-links": "^6.0.21",
    "@storybook/react-native": "^5.3.21",
    "@storybook/react-native-server": "^5.3.21",
    "babel-loader": "^8.1.0",
    "babel-preset-expo": "~8.1.0",
    "react-is": "^16.13.1"
  }
}

@bitcrumb
Copy link

Same issue.

@JeffGuKang
Copy link
Contributor Author

JeffGuKang commented Sep 14, 2020

@nidheeshdas Try yarn add @storybook/addon-actions@5.3.21

@dannyhw
Copy link
Member

dannyhw commented Sep 16, 2020

@nidheeshdas with storybook for react native you cannot use the v6 storybook libraries because it is not yet supported.

You should use the latest 5.3 version which at this moment is 5.3.21 like jeff said.

edit-

to clarify

these dependencies should be using the 5.3.21 version

 "@storybook/addon-actions": "^6.0.21",
 "@storybook/addon-essentials": "^6.0.21",
 "@storybook/addon-links": "^6.0.21",

@JeffGuKang
Copy link
Contributor Author

JeffGuKang commented Sep 17, 2020

 "@storybook/addon-actions": "^6.0.21",
 "@storybook/addon-essentials": "^6.0.21",
 "@storybook/addon-links": "^6.0.21",

Thank you.

    "@storybook/addon-actions": "5.3.21",
    "@storybook/addon-knobs": "6.0.21",
    "@storybook/addon-links": "6.0.21", // I am not using this 
    "@storybook/addons": "6.0.21",
    "@storybook/react-native": "5.3.22-alpha.1",
    "@storybook/react-native-server": "5.3.22-alpha.1",

It is my case. actions and knobs are working well with react-native-server.

@dannyhw
Copy link
Member

dannyhw commented Sep 17, 2020

@JeffGuKang since it's now working I guess I will close this issue, let me know if you want me to open it again :).

@dannyhw dannyhw closed this as completed Sep 17, 2020
@JeffGuKang JeffGuKang changed the title [addon] action error in React Native simulators [addon] addon-actions is not working v6.0.21 Sep 17, 2020
@jonathanm-tkf
Copy link

Same issue

@dannyhw
Copy link
Member

dannyhw commented Nov 27, 2020

@nidheeshdas with storybook for react native you cannot use the v6 storybook libraries because it is not yet supported.

You should use the latest 5.3 version which at this moment is 5.3.21 like jeff said.

edit-

to clarify

these dependencies should be using the 5.3.21 version

 "@storybook/addon-actions": "^6.0.21",
 "@storybook/addon-essentials": "^6.0.21",
 "@storybook/addon-links": "^6.0.21",

@jonathanm-tkf please see my previous comment.

@DanielRamosAcosta
Copy link

DanielRamosAcosta commented Feb 22, 2021

We are havving this same issue at version:

With Expo 40.

@storybook/addon-actions@6.1.18
@storybook/react-native@5.3.25"

Did you manage to solve the issue @JeffGuKang?

@dannyhw
Copy link
Member

dannyhw commented Feb 22, 2021

@DanielRamosAcosta You cannot use addon-actions v6+ please downgrade the version of @storybook/addon-actions@6.1.18 to 5.3.21.

Version 6 of storybook is not compatible with version 5.3.

@DanielRamosAcosta
Copy link

Yes! Thanks @dannyhw !

@simonadenic
Copy link

simonadenic commented Nov 21, 2023

@dannyhw Just stumbled upon the same issue with v7.

Here are my dependencies:

    "@storybook/addon-essentials": "^7.5.3",
    "@storybook/addon-interactions": "^7.5.3",
    "@storybook/addon-links": "^7.5.3",
    "@storybook/blocks": "^7.5.3",
    "@storybook/react": "^7.5.3",
    "@storybook/react-webpack5": "^7.5.3",
    "@storybook/react-native": "^7.0.0-alpha.8",
    "@storybook/addon-ondevice-actions": "^7.0.0-alpha.8",
    "@storybook/addon-ondevice-backgrounds": "^7.0.0-alpha.8",
    "@storybook/addon-ondevice-controls": "^7.0.0-alpha.8",

@dannyhw
Copy link
Member

dannyhw commented Nov 21, 2023

@simonadenic you need to use the alpha version of storybook, i.e not 7.5.3, you would use the latest alpha for 7.6. We added a fix in the 7.6 alpha recently.

@simonadenic
Copy link

Will try now, thanks a lot for a fast response :)

@simonadenic
Copy link

Works as expected with 7.6.0-alpha-6, thank you very much! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants