- Published on
Installation 💿
- Authors
-
-
- Name
- Máximo Mussini
- @maximomussini
-
Add this line to your site’s Gemfile:
gem 'jekyll-vite'
Then, run:
bundle install
bundle exec vite install
This will add the plugin in _config.yml
:
plugins:
- jekyll/vite
It will also generate a sample setup in _layouts/default.html
(if it exists):
<head>
<!-- meta tags, etc -->
{% vite_client_tag %}
{% vite_javascript_tag application %}
</head>
If you are using a theme such as
minima
, you will want to provide a custom head with these liquid tags. Or use a starter template
It also:
- Adds an exe/dev command that you can use to start both Jekyll and Vite
- Adds the bin/vite executable to start the dev server and run other commands
- Installs vite and vite-plugin-ruby
- Adds
vite.config.ts
andconfig/vite.json
configuration files - Creates a sample
application.js
entrypoint in your Jekyll site