This template should help get you started developing Wordpress plugins using Vue 3 + Tailwind.
To start your project:
git clone https://github.com/GustavoGomez092/vue-wordpress-plugin.git
Change directory into the project folder:
cd vue-wordpress-plugin
Install dependencies:
npm install
Before starting development:
npm run init
Development server:
npm run dev
Package to zip:
npm run package {{zipName}}
To avoid style conflicts with any WordPress theme that you are using for your site, the plugin by default comes with a: "tw-" prefix on all classes (this can be disabled through the tailwind.config.js
). We also added scopedPreflightStyles
to limit Tailwind's CSS style resets to only happen at plugin container level.