Skip to content

locomotivemtl/craft-boilerplate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Craft Project Boilerplate

The goal of this project is to provide a fully working "boilerplate" (empty skeleton project) using the CraftCMS project.

Table of Content

How to Install

To start a CraftCMS project with this Boilerplate, simply:

1. Installing the boilerplate

Use the Composer create-project command to install the boilerplate:

composer create-project --prefer-dist locomotivemtl/craft-boilerplate acme

Copy environment variables

Copy the .env.example.dev file to .env:

2. Setup your local environment

Using Laravel Valet

# Move into your project's directory
cd acme

# Setup valet to use PHP 8.2 only for this project
valet isolate --site acme 8.2

# Install the dependencies
valet composer install

# Run the valet installer.
valet php craft install

# Enable the Vite plugin
valet php craft plugin/install vite

Using DDEV

WIP

3. Setup Vite

Vite is a fast, modern build tool that speeds up development with instant hot reload and simplifies production bundling using native ES modules.

Add vite configurations to .env file

VITE_SERVER_URL="http://localhost"
VITE_SERVER_PORT=5173
# Make sure to set the environment to 'dev'. Otherwise, Craft won't be looking for the Vite server.
CRAFT_ENVIRONMENT=dev

4. Setup front-end tools

npm install

5. Test your installation

Start your Vite server

npm run dev

Visit your project locally http://acme.test

Dependencies and Requirements

  • PHP 8.2+
    • ext-json
    • ext-pdo
    • ext-spl
    • ext-mbstring

Development

Development dependencies

Authors

About

No description, website, or topics provided.

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •