Wagtail Start CLI

Use this CLI: https://github.com/nickmoreton/wagtail-start to start a new Wagtail CMS site.

  • Remove the default welcome page
  • Add node and npm to the project
  • Add webpack to the project

It uses the Wagtail start command and then alters the sites folder and file layout. Optionally, you can also include a basic webpack setup to build and compile the front end code.

The site will include only a base home page and is ready for development.

Installation

poetry install
bash
note code Copy code

Usage

poetry run new [project_name]
bash
note code Copy code

The project will be created in it's own directory inside the parent directory of the CLI tool.

New site development

Once the site is generated, you can start developing it further.

Backend

Install the dependencies, use your preferred method of setting up a virtual environment.

Run

python manage.py migrate
python manage.py createsuperuser
python manage.py runserver
bash
note code Copy code

Frontend

  1. Install the dependencies: (nvm use if you have nvm installed) and npm install.
  2. Run the dev server: npm start.
  3. Open the site in your browser: http://localhost:3000.
  4. For production build: npm run build.