Getting started with Vite, a no bundler DEV environment for Vue.js

Introduction

What does Vite mean?

Why use Vite?

Getting started

npx create-vite-app <project-name>
cd <project-name>
npm install
npm run dev

Testing Hot Module Replacement

<template>    <div class="hello">        <h1>{{ msg }}</h1>        <button @click="count++">count is: {{ count }}</button>        <p>Edit <code>components/HelloWorld.vue</code> to test hot module replacement.</p>    </div></template>
<template>    <div class="hello">        <h1>Hello Vite: {{ msg }}</h1>        <button @click="count++">count is: {{ count }}</button>        <p>Edit <code>components/HelloWorld.vue</code> to test hot module replacement.</p>    </div></template>

Conclusion

--

--

Lead developer, specialising in Vue, Nuxt and Laravel. Author of Vue Barebones component library.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Liam Hall

Lead developer, specialising in Vue, Nuxt and Laravel. Author of Vue Barebones component library.