Download the PHP package arrowsgm/amped-laravel without Composer

On this page you can find all versions of the php package arrowsgm/amped-laravel. 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 amped-laravel

Amped Laravel

This package adds possibility to convert existing html content to amp-html. The package uses AMP Plugin for WordPress for content sanitizing and some helper functions from Wordpress for amp-wp plugin.

AMP is a fast-growing framework, but unfortunately, currently, there are no (or at least I can't find it) any working solutions, which can help to provide a valid html to amp-html code converter. According to ampproject/amp-wp#2315, @amproject is preparing to release a PHP-library independent from any CMS, but until that time using amp-wp plugin as a content sanitizer is an easiest solution, even if it has many Wordpress-related code. If you have any issue with package sanitizer, you can easily swap it with your own, just making changes in provided config.

Requirements

Update from versions < 0.4.x

You need to change repository url in your composer.json from https://github.com/ampproject/amp-wp to https://github.com/arrowsgm/amp-wp, this is a hard-forked version 1.4.4 of the ampproject/amp-wp package with updated dependencies.

Installation

Add to your composer.json repositories section link to amp-wp plugin:

when require package as usual:

Using

You can publish configuration with artisan command:

or just create amped.php file in the config directory and change required params only.

To convert existing content use provided Amped facade:

You can use Amped facade in the blade templates, alias already provided:

Amped class also have inlineCss method to adding custom styles from css file:

and you can set base amp styles directory with amp_custom_css_path config param.

isDevParam method is useful for amp link building. It returns #development=1 string if laravel application debugging is on:

and you can easily navigate through the existing posts with in-browser AMP validation enabled.


All versions of amped-laravel with dependencies

PHP Build Version
Package Version
Requires ampproject/amp-wp Version dev-main
ext-libxml Version *
ext-dom Version *
ext-json Version *
guzzlehttp/guzzle Version ~6.0|^7.0
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 arrowsgm/amped-laravel contains the following files

Loading the files please wait ....