Code Monkey home page Code Monkey logo

better-wpdb's Introduction

Snicco - Taking the pain out of enterprise WordPress development

codecov Psalm Type-Coverage Psalm level PhpMetrics - Static Analysis PHP-Versions

In this development monorepo you'll find many independent packages that will help you to develop testable, maintainable and PSR-compatible enterprise WordPress projects faster than ever before.

All packages in this repo are specifically designed to be usable in distributed WordPress code and are scopable out of the box.

Table of contents

  1. Repository Overview
    1. Component
    2. Bridge
    3. Middleware
    4. Bundle
    5. Testing
  2. Contributing
  3. Changelog
  4. Security
  5. License
  6. Credits

Repository Overview

You can find all packages in the src/Snicco directory.

Here is a brief overview of the repository: (hint: click the links to go to the dedicated documentation for each package)

Component

This directory contains completely decoupled PHP components that you can use in any WordPress (or any other PHP project) .

  • BetterWPAPI: A better way to interacts with WordPress core functions in distributed WordPress packages.
  • BetterWPCache: A PSR6/PSR16 implementation using the WP_Object_Cache. Supports cache tagging.
  • BetterWPCLI: The missing parts to the already awesome WP-CLI.
  • BetterWPHooks: The WordPress hook system redesign in 2022. (PSR-14 compliant)
  • BetterWPMail: The long overdue upgrade to the wp_mail function.
  • BetterWPDB: Keeps you safe and sane when working with custom tables in WordPress.
  • EventDispatcher: A general purpose, PSR-14 compliant event-dispatcher that powers snicco/better-wp-hooks.
  • HttpRouting: A blazing fast routing system and PSR7/PSR15 middleware dispatcher based on fast-route. Especially build for usage in legacy software where you don't have 100% control over the request-lifecycle.
  • Kernel: A minimal and customizable application bootstrapper.
  • Psr7ErrorHandler: A powerful, PSR-7/PSR-3 compliant error-handler.
  • Session: A custom session implementation for applications where $_SESSION can't be used for various reasons.
  • SignedURL: A standalone package to generate and validate protected urls.
  • StrArr: A zero-dependency,type-safe and psalm-compatible implementation of the illuminate/support string and array helpers.
  • Templating: A unified, immutable API for using and combining different template engines.
  • TestableClock: Helper classes for testing time-dependent code.

Bridge

This directory contains different implementations for interfaces defined in one of the components.

Middleware

This directory contains PSR15-Middleware that can be plugged into the snicco/http-routing component.

  • DefaultHeaders: Add custom headers to all outgoing responses.
  • HttpsOnly: Redirects HTTP => HTTPS for all requests
  • MethodOverride: Allows treating form submissions as PUT|PATCH|DELETE requests.
  • Negotiation: Performs content and language negotiation
  • NoRobots: Disallows search-engines to index the current request path.
  • Payload: Transforms JSON (and other) data to plain PHP arrays.
  • Redirect: Redirects requests to configured locations.
  • ShareCookies: Transforms cookie objects into response headers.
  • TrailingSlash: Redirects /foo/ to /foo or vice-versa.
  • WPAuthOnly: Grants access only to authenticated WordPress users.
  • WPCapability: Grants access only to WordPress users with the configured capability.
  • WPGuestsOnly: Grants access only to guest WordPress users.
  • WPNonce: Will solve all your WordPress Nonces problems once and for all.

Bundle

A bundle is a plugin for the snicco/kernel component and integrates one or more components or bridges to provide out of the box functionality.

While all components can absolutely be used without using the snicco/kernel component, bundles makes usage and configuration effortless.

Testing

This directory contains testing utilities for components. These packages are only meant to be used as development dependencies.

Contributing

We've set up a separate document for our contribution guidelines.

Changelog

Our changelog is automatically generated using the wonderful npm package semantic-release.

Security

Please review our security policy on how to securely report vulnerabilities.

License

This project is licensed under the terms of the GNU LGPLv3 unless otherwise specified in the respective LICENSE.md file of each package. See LICENSE.md

Credits

We want to express our special gratitude to:

better-wpdb's People

Contributors

snicco-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  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.