Get started with Vulmix
Pre-requisites
Before getting started with Vulmix, you need to make sure you have the following installed:
Vulmix still doesn't support PNPM.
Installation
To scaffold a new Vulmix project, you can use the create-vulmix-app
CLI tool:
npx create-vulmix-app your-app-name
Once the install is complete, get into your project folder and install Vulmix dependencies:
cd your-app-name
# With NPM
npm install
# Or with Yarn
yarn install
Running the project
Run the project locally by going into the project directory and then running the dev
command:
# With NPM
npm run dev
# Or with Yarn
yarn dev
This should serve your project on an automatically picked port of localhost (default is 3000
) with HMR enabled.
Then you should see the following page on your browser:
Now you can start building your application right away in the app.vue
file by replacing the <VulmixWelcome />
component with your own content.
Preparing for production
To compile an optimized build, you need to run the prod
command:
# With NPM
npm run prod
# Or with Yarn
yarn prod
This will minify and optimize your project code in the _dist
folder which you can deploy its contents on any static host.
If you are hosting your project on Vercel, it will automatically generate a production build.
Testing your production build locally
If you want to test your project after running the prod
command, you can run the serve
command to raise a server on the 8000
port:
# With NPM
npm run serve
# Or with Yarn
yarn serve
Then you can open you project at localhost:8000
.
Your assets will be served with Gzip compression.