:-: .==-+: .==. :+- .-=- .==. :==++-+=. :==. -**: :+=. :+- :*+++. .++. :+- -*= .++: .=+. -+: =*- .+*: .=+:
With a few easy steps, you can get a production ready app in minutes, and Nuxt.js will automatically configure your app with provided options to essentially any specification. Let's take a look.
Vue.js solves the same problems that React does for front-end development, but in very different ways which means they could have different use cases in a variety of scenarios. It's ultimately up to you to decide which one is better suited to your needs, so hopefully this article will explain some pros and cons that Vue.js/Nuxt.js will have for your consideration, especially if you are already familiar with React.
To install, you can use NPM or Yarn, which will install the Nuxt.js package to your project folder.
When you run the create command, the console will prompt you with options for your app build specifications. You can choose a front end UI framework, server-side framework, middleware, routing, etc. Or you can click through and start from scratch, because Vue.js/Nuxt.js are designed to be open ended and versatile to suite any project. This trait also allows Vue.js apps to be integrated into an existing project with east.
For my demo, I chose the following settings:
Once you've chosen the settings the app will install. Once the app in installed type:
Nuxt.js is indexed by search, so will perform better in search engine's than a standard Vue.js build. It comes pre configured with Vue Router and Vue-meta, and Vuex, which are not included by default with Vue.
Vue also has no standard file structure, so Nuxt.js provides us with one as well. For routing, Nuxt.js gives you a pages folder, that will automatically set up routes when you place a single component file within it. Let's see how our build is doing in the console.
The app was generated and immediately available for development on my localhost. Time to add some code!