Download the PHP package jascha030/wp-sequoia without Composer

On this page you can find all versions of the php package jascha030/wp-sequoia. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package wp-sequoia

Sequoia

A Cheeky Component library for PHP, using the Twig templating language library and an OOP approach. Built with Wordpress in mind but not limited to Wordpress.

Prerequisites

Installation

Require as dependency by either; adding it directly to your composer.json, or running:

Simple as that…

Usage

It’s all based around two interfaces:

TwigTemplaterInterface and the TwigComponentInterface and it’s main implementation TwigComponentAbstract.

Templater

Create a Templater which requires a Twig\Environment instance. (Preferably using a FilesystemLoader).

Example

Let’s say you have a template in your templates folder called list-template.twig

Now you can extend the TwigComponentAbstract.

Which can then be rendered like:

Using default values

You can also provide, defaults for a component using the HasDefaultContextTrait like:

With Wordpress

When available the getContext method used in rendering, will have an automatically generated filter, to mutate the defaults following the pattern:

twig_template_context_{$this->getTemplateSlug()}

Where $this->getTemplateSlug() will by default return the template name defined in the getTemplate() method, minus the .twig appendix, in the above example this would be: twig_template_context_list-template, which could then be used in the following context (in Wordpress):

Now you would hypothetically have added a third list item and the output of the ListComponent::render() method would be:

Running UnitTests

To check wether your implementation is allright or if there is something wrong with the library while extending it. you can use:

Make sure to install with dev dependencies by using composer install instead of composer install —no-dev.

More comming soon.

Inspiration

This is the start of a library based around the frustration with Wordpress, their messy template system, their messy user base, and the sadly, lately rarely updated timber/timber library and it’s overkill set of features.

It’s pretty specific and built mainly for myself and to make Front-end features a bit more fun to develop.

But maybe someone will ever find some use in this library as I hope to extend it and add loads of features, until it will reach a point of being just as overkill as timber.

That being said, timber/timber is a great library so support it if you use it, and even though Wordpress’ messy and old-timey nature, It’s a great tool for those who are learning or don’t aspire to be developers to build their website, which is obviously, why it has seen the great success, that it has.

And for those who are aspiring to be developers, beware of the fact that the coding styles of Wordpress are a great starting point, they are not how we develop code in the rest of the world, and based around old, long forgotten standards.

Shout out to those few internet heroes, who are finding and teaching how to do Wordpress development, in a more modern fashion.

If you are one who aspires to be one or is just plain bored by having to work with Wordpress, I suggest googling people like:

  • Carl Alexander
  • Josh Pollock
  • The people from Roots (from bedrock, sage)

All versions of wp-sequoia with dependencies

PHP Build Version
Package Version
Requires twig/twig Version ^3.3
symfony/finder Version ^5.3
php Version ^7.4
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package jascha030/wp-sequoia contains the following files

Loading the files please wait ....