Repository: nuxt/create-nuxt-app
Pull request #632 (2020-10-07 13:34:05)

feat: add route page and content fetch
@clarkdo I am not sure how to run it locally to see if it works so please can you check this out:

This is all from feedback from when using this during live streams with developers new to Nuxt. Here is what has been added:

1. improved wording for features as people don't always know what content is - also added desc for axios
2. added a route to a simple page as when we create the app we only show links to external site and would be nice to show an internal link using NuxtLink as this is new for many users starting out with Nuxt
3. If content is selected also add a content page which fetches the the content and renders it on the page. Really useful as if not the content folder is created and nobody knows what to do with it so having a working example will really help

Any suggestions and improvements welcome

clarkdo: Nice, I’ll have a look later today.

Patch:
diff --git a/README.md b/README.md
index 7269cd7..ce1c33b 100644
--- a/README.md
+++ b/README.md
@@ -51,9 +51,9 @@ yarn create nuxt-app <my-project>
     - [Vuesax](https://github.com/lusaxweb/vuesax)
     - [Vuetify](https://github.com/vuetifyjs/vuetify)
 1. Nuxt.js modules:
-    - [Axios](https://github.com/nuxt-community/axios-module)
+    - [Axios - Promise based HTTP client](https://github.com/nuxt-community/axios-module)
     - [Progressive Web App (PWA)](https://github.com/nuxt-community/pwa-module)
-    - [Content](https://github.com/nuxt/content)
+    - [Content - Git-based headless CMS](https://github.com/nuxt/content)
 1. Linting tools:
     - [ESLint](https://github.com/nuxt/eslint-config)
     - [Prettier](https://github.com/prettier/prettier)
diff --git a/packages/create-nuxt-app/lib/prompts.js b/packages/create-nuxt-app/lib/prompts.js
index 4dccde5..f26c4c7 100644
--- a/packages/create-nuxt-app/lib/prompts.js
+++ b/packages/create-nuxt-app/lib/prompts.js
@@ -52,9 +52,9 @@ module.exports = [
     type: 'checkbox',
     pageSize: 10,
     choices: [
-      { name: 'Axios', value: 'axios' },
+      { name: 'Axios - Promise based HTTP client', value: 'axios' },
       { name: 'Progressive Web App (PWA)', value: 'pwa' },
-      { name: 'Content', value: 'content' }
+      { name: 'Content - Git-based headless CMS', value: 'content' }
     ],
     default: []
   },
diff --git a/packages/create-nuxt-app/lib/saofile.js b/packages/create-nuxt-app/lib/saofile.js
index af2f176..1b371f0 100644
--- a/packages/create-nuxt-app/lib/saofile.js
+++ b/packages/create-nuxt-app/lib/saofile.js
@@ -56,7 +56,8 @@ module.exports = {
       templateDir: join(templateDir, 'nuxt'),
       filters: {
         'static/icon.png': 'features.includes("pwa")',
-        'content/hello.md': 'features.includes("content")'
+        'content/hello.md': 'features.includes("content")',
+        'pages/content.vue': 'features.includes("content")'
       }
     }]
 


Test patch:
diff --git a/packages/create-nuxt-app/test/snapshots/index.test.js.md b/packages/create-nuxt-app/test/snapshots/index.test.js.md
index da07def..f79fb74 100644
--- a/packages/create-nuxt-app/test/snapshots/index.test.js.md
+++ b/packages/create-nuxt-app/test/snapshots/index.test.js.md
@@ -584,7 +584,7 @@ Generated by [AVA](https://avajs.dev).
     }␊
     `
 
-## verify features: Axios
+## verify features: Axios - Promise based HTTP client
 
 > Generated files
 
@@ -672,7 +672,7 @@ Generated by [AVA](https://avajs.dev).
     }␊
     `
 
-## verify features: Axios, Progressive Web App (PWA), Content
+## verify features: Axios - Promise based HTTP client, Progressive Web App (PWA), Content - Git-based headless CMS
 
 > Generated files
 
@@ -771,7 +771,7 @@ Generated by [AVA](https://avajs.dev).
     }␊
     `
 
-## verify features: Content
+## verify features: Content - Git-based headless CMS
 
 > Generated files