From 888a9ecbf246f256c159e541da2ddad074240636 Mon Sep 17 00:00:00 2001 From: Sebastien Chopin Date: Fri, 18 Aug 2017 15:44:43 +0200 Subject: [PATCH] Add spa example --- examples/spa/nuxt.config.js | 20 ++++++++++++++++++++ examples/spa/package.json | 11 +++++++++++ examples/spa/pages/about.vue | 16 ++++++++++++++++ examples/spa/pages/index.vue | 6 ++++++ 4 files changed, 53 insertions(+) create mode 100644 examples/spa/nuxt.config.js create mode 100644 examples/spa/package.json create mode 100644 examples/spa/pages/about.vue create mode 100644 examples/spa/pages/index.vue diff --git a/examples/spa/nuxt.config.js b/examples/spa/nuxt.config.js new file mode 100644 index 0000000000..9f8220c71e --- /dev/null +++ b/examples/spa/nuxt.config.js @@ -0,0 +1,20 @@ +module.exports = { + mode: 'spa', + loadingIndicator: { + /* + ** See https://github.com/nuxt/nuxt.js/tree/dev/lib/app/views/loading for available loading indicators + ** You can add a custom indicator by giving a path + ** Default: 'circle' + */ + name: 'folding-cube', + /* + ** You can give custom options given to the template + ** See https://github.com/nuxt/nuxt.js/blob/dev/lib/app/views/loading/folding-cube.html + ** Default: + ** - color: '#3B8070' + ** - background: 'white' + */ + color: '#222', + background: '#eee' + } +} diff --git a/examples/spa/package.json b/examples/spa/package.json new file mode 100644 index 0000000000..92325ecf81 --- /dev/null +++ b/examples/spa/package.json @@ -0,0 +1,11 @@ +{ + "name": "hello-nuxt", + "dependencies": { + "nuxt": "latest" + }, + "scripts": { + "dev": "nuxt", + "build": "nuxt build", + "start": "nuxt" + } +} diff --git a/examples/spa/pages/about.vue b/examples/spa/pages/about.vue new file mode 100644 index 0000000000..5779a3b22f --- /dev/null +++ b/examples/spa/pages/about.vue @@ -0,0 +1,16 @@ + + + diff --git a/examples/spa/pages/index.vue b/examples/spa/pages/index.vue new file mode 100644 index 0000000000..9655d7d866 --- /dev/null +++ b/examples/spa/pages/index.vue @@ -0,0 +1,6 @@ +