Ledger Nano X - The secure hardware wallet
SHARE
TWEET

Untitled

a guest Mar 30th, 2020 73 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. asyncData(context) {
  2.     // Check if we are in the editor mode
  3.     let version =
  4.       context.query._storyblok || context.isDev ? "draft" : "published";
  5.  
  6.     return context.app.$storyapi
  7.       .get(`cdn/stories/nyheder/${context.params.slug}`, {
  8.         version
  9.       })
  10.       .then(res => {
  11.         return res.data;
  12.       })
  13.       .catch(res => {
  14.         context.error({
  15.           statusCode: res.response.status,
  16.           message: res.response.data
  17.         });
  18.       });
  19.   },
  20.   mounted() {
  21.     this.$storybridge.on(["input", "published", "change"], event => {
  22.       if (event.action == "input") {
  23.         if (event.story.id === this.story.id) {
  24.           this.story.content = event.story.content;
  25.         }
  26.       } else {
  27.         window.location.reload();
  28.       }
  29.     });
  30.   },
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Top