From fb9902842dd8ed6d22db6aa78c70ca6ac4ae105c Mon Sep 17 00:00:00 2001 From: Sam Verschueren Date: Fri, 11 Jun 2021 01:44:22 +0200 Subject: [PATCH] docs(examples/with-redux-persist): add 'Open in StackBlitz' button (#25972) Add `Open in StackBlitz` button to `examples/with-redux-persist` and `examples/with-videojs`. #### with-redux-persist At first we though the example didn't work correctly in WebContainer because it shows the following message > redux-persist failed to create sync storage. falling back to noop storage. After investigating this, we saw the same message on local as well and is probably intended behaviour because of SSR. The example works, but it makes sense that it can't get the local storage on the server side and that's what causing the message. #### with-videojs The video's couldn't be played in the preview frame before. I fixed it on our end and thus also added the StackBlitz button. ## Bug - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added ## Feature - [ ] Implements an existing feature request or RFC. Make sure the feature request has been accepted for implementation before opening a PR. - [ ] Related issues linked using `fixes #number` - [ ] Integration tests added - [ ] Documentation added - [x] Example(s) updated - [ ] Telemetry added. In case of a feature if it's used or not. ## Documentation / Examples - [x] Make sure the linting passes --- examples/with-redux-persist/README.md | 6 ++++++ examples/with-videojs/README.md | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/examples/with-redux-persist/README.md b/examples/with-redux-persist/README.md index adeca8876e98b..80caf652424b7 100644 --- a/examples/with-redux-persist/README.md +++ b/examples/with-redux-persist/README.md @@ -4,6 +4,12 @@ This example shows how to integrate Redux with the power of Redux Persist in Nex With the advantage of having a global state for your app using `redux`. You'll also require some of your state values to be available offline. There comes `redux-persist` using which you can persist your states in browser's local storage. While there are various ways of persisting your states which you can always find in there [documentation](https://github.com/rt2zz/redux-persist/blob/master/README.md). This is an example of how you can integrate `redux-persist` with redux along with Next.js's universal rendering approach. +## Preview + +Preview the example live on [StackBlitz](http://stackblitz.com/): + +[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/vercel/next.js/tree/canary/examples/with-redux-persist) + ## Deploy your own Deploy the example using [Vercel](https://vercel.com?utm_source=github&utm_medium=readme&utm_campaign=next-example): diff --git a/examples/with-videojs/README.md b/examples/with-videojs/README.md index 58cf100cd7413..0429d5efa8a57 100644 --- a/examples/with-videojs/README.md +++ b/examples/with-videojs/README.md @@ -2,6 +2,12 @@ This example shows how to use Next.js along with [Video.js](https://videojs.com) including handling of default styles. +## Preview + +Preview the example live on [StackBlitz](http://stackblitz.com/): + +[![Open in StackBlitz](https://developer.stackblitz.com/img/open_in_stackblitz.svg)](https://stackblitz.com/github/vercel/next.js/tree/canary/examples/with-videojs) + ## Deploy your own Deploy the example using [Vercel](https://vercel.com?utm_source=github&utm_medium=readme&utm_campaign=next-example):