Skip to content
This repository has been archived by the owner on Apr 22, 2020. It is now read-only.

inpsyde/wordpress-core-autoloader

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 

WordPress core autoloader proposal

Hello and welcome! This is a proposal on a WordPress class autoloader mentioned in the core trac ticket 36335

The goal is to provide a full featured, well tested proposal on how a autoload module for the WordPress core could look like.

Contribution is highly appreciated!

Current Status: very early draft

Conceptual basic points

The implementation:

  • must support PHP 5.2 even without SPL enabled
  • should deal with case-insensitivity
  • should be object orientated following SOLID principles
  • should be completely unit tested (tests are made in isolation)
  • should be completely documented

The current development requirements are set to 5.4. Tests will be made backward compatible later.

Current questions

For the following questions, pros and cons have to be listed, discussion and decisions have to be made:

  • Supporting a configuration file for autoloading rules?
  • Provide caching for autoloading rules? (Means caching the resolved file paths?)
  • Should the support for no-SPL implemented internally by investigating every rule and turn it to a static class map? Or should it be a public interface in the API (e.g. $autoloader->add_spl_fallback_rule())?

About

A proposal for a core WordPress autoloader module.

Resources

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages