-
Notifications
You must be signed in to change notification settings - Fork 55
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
Integrate Expo Snack into docs #305
Comments
Hi, @carbonrobot, @zibs
Expo Snack: https://snack.expo.dev/@mrpmohibur/486cbe?platform=web Please, note that I can successfully run expo managed project locally, with the same versions of libraries on the given expo snack above. If anyone has any idea on how to solve this, I can implement expo snacks for all the example codes. |
Hey @mrpmohiburrahman, thanks for your efforts here! Based on your snack, it looks like you're trying to integrate against the older versions of victory-native, whereas we want to use the latest versions and implementation of the library here! There is no more For the snack error itself, have you taken a look at the link in the issue above^ https://shopify.github.io/react-native-skia/docs/getting-started/web/#using-code-splitting? I think that might help! |
@zibs , sorry for the late reply. Right now, I am getting a new error
snack link: https://snack.expo.dev/@mrpmohibur/simple-line-chart I already have implemented the expo snack on the doc, but stuck on this error. |
@mrpmohiburrahman [email protected] |
The issue regarding You can see in this snack https://snack.expo.dev/@robwalker/xywhrect-error-example that when switching to iOS or Android, the graph renders correctly. This is because We could add Snacks to the docs and set the default platform to Android or iOS, but the viewer would need to press the I suggest we focus on fully supporting the web as a platform before adding Expo Snacks to the docs. |
I've opened a PR to fix issues with using Victory Native on the web, but it's not possible to use dependencies directly from GitHub within a Snack. For that reason, I'm currently blocked from continuing on any Expo Snack work until the PR is merged and deployed. |
Will it be ok if I do the integration of expo snack when your PR get merged ? |
@mrpmohiburrahman We appreciate any contributions! Once the PR is merged, I may (depending on other work commitments) start on an initial Snack integration on the Getting Started docs page immediately, just to check if it's possible! Feel free to open your own PR, though, as I may not be able to work on it immediately. It would be great to include Snacks for all suitable docs pages eventually, so your help with that would also be amazing. |
I can work on it full-time ( as currently, I don't have any office work ). |
Just noticed, the PR got merged. |
@mrpmohiburrahman It's just been published to npm - https://www.npmjs.com/package/victory-native/v/41.1.0 |
@mrpmohiburrahman I've managed to get a working snack - https://snack.expo.dev/@robwalker/victory-native-snack-example It's a bit fiddly, as it needs to be code-split so that Skia is not initialised until after |
Another blocker :( It's only possible to view the For us, the App.tsx file will have to be Skia Web wrapping code. The embedded snack will not show or allow editing of the actual chart code, unless the Snack is opened on the full Expo Snack interface using the icon on the snack. This is a screenshot of what our embedded snacks will look like @mrpmohiburrahman have you been able to get a working snack where the |
Unfortunately no, The problem is the import() statement on getComponent(). |
I've opened a PR to add a feature to Expo Snack which will allow us to specify the file to show in the snack. |
Is now Victory Native 41.8.0 has support for web? cause i still got this error when using it with Expo 51 with all instructions from skia web setup.
|
@kyoto21 There is no official web support yet, but we have it on the feature request list |
Thanks, glad to hear that. I'll just stick with victory native legacy a lil bit longer then |
Integrate Expo Snack into the docs site similar to how to do examples for Victory Web.
The text was updated successfully, but these errors were encountered: