Giter Site home page Giter Site logo

joelgrodriguez / tailpress Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jeffreyvr/tailpress

0.0 1.0 0.0 3.03 MB

TailPress is a minimal boilerplate theme for WordPress using Tailwind CSS.

Home Page: https://tailpress.io

License: MIT License

CSS 8.58% PHP 77.25% JavaScript 14.17%

tailpress's Introduction

TailPress

GitHub release License

Introduction

TailPress is a minimal boilerplate theme for WordPress using Tailwind CSS.

Getting started

Using the installer

You can get started using the installer (using composer):

composer global require jeffreyvanrossum/tailpress-installer

tailpress new example-theme

If the tailpress command is not found, make sure to place Composer's global vendor bin in your $PATH (see).

Flags you can pass when using the installer:

  • Set a theme name --name="Example Theme"
  • Choose your compiler, mix or esbuild: --compiler="esbuild"
  • Initialize a git repository --git
  • Set the git branch name --branch="main"

If you choose to install WordPress through the installer, these flags might be of interest as well: --dbname, --dbuser, --dbpass and --dbhost.

Once your theme is ready, don't forget to cd into the directory.

You will be asked if you would like to have WordPress installed as well. Keep in mind that you still need a local development environment for PHP and MySQL.

Regular method

  • Clone repo git clone https://github.com/jeffreyvr/tailpress.git && cd tailpress
  • Run rm -rf .git to remove git (or rmdir .git for Windows)
  • Run npm install
  • Run npm run watch to start developing

General

You will find the editable CSS and Javascript files within the /resources folder.

Before you use your theme in production, make sure you run npm run production.

NPM Scripts

There are several NPM scripts available. You'll find the full list in the package.json file under "scripts". A script is executed through the terminal by running npm run script-name.

Script Description
production Creates a production (minified) build of app.js, app.css and editor-style.css.
dev Creates a development build of app.js, app.css and editor-style.css.
watch Runs several watch scripts concurrently.

Tips

Styling within the block editor

To make the editing experience within the block editor more in line with the front end styling, a editor-style.css is generated.

CSS classes generated by TailPress

CSS classes for alignment (full, wide etc.) are generated automatically. You can opt-out on this by removing the plugin from the tailwind.config.js file.

Customize colors

Several colors and font sizes are defined from the beginning. You can modify them in theme.json.

Command tailpress not found

Make sure to place Composer's global vendor bin directory in your $PATH so the tailpress executable can be found by your system. This directory exists in different locations based on your operating system; however, some common locations include:

  • macOS: $HOME/.composer/vendor/bin
  • Windows: %USERPROFILE%\AppData\Roaming\Composer\vendor\bin
  • GNU / Linux Distributions: $HOME/.config/composer/vendor/bin or $HOME/.composer/vendor/bin

You could also find the composer's global installation path by running composer global about and looking up from the first line.

Links

Contributors

License

MIT. Please see the License File for more information.

tailpress's People

Contributors

jeffreyvr avatar dependabot[bot] avatar justingolden21 avatar ecastillo avatar davidangel avatar jarednthomas avatar tim-the-arcane avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.