smonist / craft-vite-starter
Craft CMS 5 with DDEV & Vite
Package info
github.com/szenario-fordesigners/craft-vite-starter
Type:project
pkg:composer/smonist/craft-vite-starter
Requires
- craftcms/ckeditor: 5.7.0
- craftcms/cms: 5.11.3
- nystudio107/craft-vite: 5.0.2
- vlucas/phpdotenv: 5.7.0
Requires (Dev)
- craftcms/generator: 2.2.0
- yiisoft/yii2-shell: 2.0.6
Suggests
None
Provides
None
Conflicts
None
Replaces
None
- dev-main
- 3.0.0
- 2.5.2
- 2.5.1
- 2.5.0
- 2.4.9
- 2.4.8
- 2.4.7
- 2.4.6
- 2.4.5
- 2.4.4
- 2.4.3
- 2.4.2
- 2.4.1
- 2.4.0
- 2.3.1
- 2.3.0
- 2.2.2
- 2.2.1
- 2.2.0
- 2.1.1
- 2.1.0
- 2.0.9
- 2.0.8
- 2.0.7
- 2.0.6
- 2.0.5
- 2.0.4
- 2.0.3
- 2.0.2
- 2.0.1
- 2.0.0
- 1.2.5
- 1.2.4
- 1.2.3
- 1.2.2
- 1.2.1
- 1.2.0
- 1.1.6
- 1.1.5
- 1.1.4
- 1.1.3
- 1.1.2
- 1.1.1
- 1.1.0
- 1.0.7
- 1.0.6
- 1.0.5
- 1.0.4
- 1.0.3
- 1.0.2
- 1.0.1
- 1.0.0
This package is auto-updated.
Last update: 2026-09-30 11:03:36 UTC
README
What if tooling was done with 1 command? Craft CMS 5 infused with Vite, TypeScript and tailwindcss. Lightning fast development, HMR and a production ready build process.
Made possible by
The team behind the magic
Simon Wesp Thomas Bendl
Turbostart 🚀
bash <(curl -s https://raw.githubusercontent.com/szenario-fordesigners/craft-vite-starter/main/init.sh)
Quickstart
mkdir my-project && cd my-projectddev config --project-type=craftcms --docroot=webddev composer create-project -n szenario-fordesigners/craft-vite-startermake installmake dev
Tech Stack
Requirements
- DDEV
- Unix-based OS (MacOS, Linux, WSL2)
If you are on Windows
Use WSL2 and follow the instructions for Unix-based OS. DDEV Documentation is a great starting point.
Commands
make install- patches the DDEV craft config and installs Craft CMS. Should only be used as a first time setup.make dev- starts the development servermake build- bundles the assets for productionmake share- starts the development server and a publicddev sharetunnel with working HMR. ngrok by default; for no account, runddev config global --share-default-provider=cloudflaredonce
Subsequent Use
ddev yarn- for managing frontend packagesddev composer- for managing backend packagesddev craft- exposes the Craft CLI
Responsive Images
This starter kit comes with named AVIF and WebP image transforms (avif480 … avif3840, webp480 … webp3840, no upscaling). Render every image through the component, which builds the srcset from them:
{% include "_includes/components/image.twig" with { asset: entry.image.one(), sizes: "(min-width: 768px) 50vw, 100vw" } only %}
Set sizes for any image narrower than the viewport and priority: true for the above-the-fold (LCP) images. The other lazy images fade in via lazyish. All params are documented at the top of templates/_includes/components/image.twig. For a lightbox or download link, use the webp3840 transform.
Credits
This repository is based on the official Craft CMS starter template.
Thanks to Andrew Welch for the great craft-vite plugin!
Contributors
Simon Wesp 💻 |
Thomas Bendl 💻 |
Esteban Castro 💻 |
