定制 wp-forge/wp-plugin 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

wp-forge/wp-plugin

最新稳定版本:1.0.5

Composer 安装命令:

composer require wp-forge/wp-plugin

包简介

Create a new WordPress plugin via Composer

README 文档

README

A WordPress plugin scaffolding template that can be easily installed using Composer.

Requirements

Installation

Run this command in the terminal:

composer --remove-vcs create-project wp-forge/wp-plugin

Be sure to append a directory name to the end of the command to customize the folder name that your project will be installed into!

The installation process will check your environment for the required PHP version and PHP extensions. If this presents a problem and you want to force install anyway, just add the --ignore-platform-reqs flag to the command.

Notes

  • The .scripts and .templates folders are used for scaffolding purposes only and won't exist in your end project.
  • We use the @wordpress/env package to provide a local development environment. This package requires Docker to be installed on your machine. If you don't want to use Docker, you can remove the @wordpress/env package from the package.json file and delete the .wp-env.json file.
  • We use the concept of a hooks folder. Rather than having a bunch of WordPress hooks scattered around your plugin, the hooks folder contains an actions and filters folder where each file name corresponds to the name of a hook (except with dashes in place of underscores). All items that belong in a particular hook are added to the appropriate file, making it easy to find, edit, and add hooks in a consistent way.
  • This repo has a source folder, where you can store any files that require a build step (e.g. scss and js). The assets folder is where you store the compiled files that will be used in your plugin. By default, we .gitignore the assets/css and assets/js folders.
  • Currently, this template does not implement any kind of build process. This is something that will be added in the future.
  • This repo creates an .nvmrc file. If you use NVM, you'll be able to run nvm use to automatically switch to the correct version of Node for this project. It will default to the version of Node that is running on your machine at the time of install.
  • This template creates GitHub Action workflows for your plugin. If you are publicly releasing your plugin on the WordPress.org plugin directory, you will need to add a SVN_USERNAME and SVN_PASSWORD environment variable to your GitHub repository settings.
  • If your plugin is to be publicly released, the .wporg folder is used to store the assets that will be uploaded to the WordPress.org plugin repository.

Reminders

Don't forget to:

  • Run git remote add origin <url> to add your remote repository
  • Add a SVN_USERNAME and SVN_PASSWORD environment variable to your GitHub repository settings (if your plugin is to be publicly released)
  • Push your code to GitHub by running git push -u origin master

统计信息

  • 总下载量: 13
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 2
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-2.0-or-later
  • 更新时间: 2023-11-03

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固