- Published on
Development ๐ป
- Authors
-
-
- Name
- Mรกximo Mussini
- @maximomussini
-
Run exe/dev
(added during installation) to start both Vite and Jekyll for development.
It will use your config/vite.json
configuration, which can be
used to configure the host
and port
, as well as other options.
Visit your Jekyll site and you should see a printed console output: Vite โก๏ธ Ruby
.
Alternatively, run bin/vite dev to start the Vite development server, and restart your Jekyll server with bin/jekyll serve once Vite is running.
Entrypoints โคต๏ธ
Any files inside your entrypointsDir will be considered entries to your application.
_frontend: sourceCodeDir
โโโ entrypoints: entrypointsDir
โ # only Vite entry files here
โ โโโ application.js
โ โโโ typography.css
โโโ components:
โ โโโ App.jsx
โโโ stylesheets:
โ โโโ main.scss
โโโ images:
โโโ logo.svg
These files will be automatically detected and passed on to Vite, all configuration is done for you.
You can add them to your HTML layouts or views using the provided tag helpers.
Import Aliases ๐
For convenience, ~/
and @/
are aliased to your sourceCodeDir,
which simplifies imports:
import App from '~/components/App.jsx'
import '@/stylesheets/main.scss'
CLI Commands โจ๏ธ
A CLI tool is provided, you can run it using bundle exec vite, or bin/vite after installation.
For information about the CLI options run bin/vite --help.