mcustiel/inlineassets-plugin

This package is abandoned and no longer maintained. No replacement package was suggested.
There is no license information available for the latest version (v1.0.1) of this package.

Provides inlineStyles and inlineScripts that embed the assets in the HTML

Installs: 709

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 2

Forks: 0

Open Issues: 0

Type:october-plugin

v1.0.1 2016-10-07 12:37 UTC

This package is auto-updated.

Last update: 2023-07-19 06:32:40 UTC


README

OctoberCMS plugin that provides embedding of assets to pages.

Twig tags

inlineStyles

Embeds the content of the add css files into the HTML code.

Example

  • Component.php
$this->addCss('my/style.css');
  • my/style.css
a {
    color: red;
}
  • twig.htm:
<head>
    {% inlineStyles %}
</head>
  • HTML result:
<head>
    <style type="text/css">
    a {
        color: red;
    }
    </style>
</head>

inlineScripts

The behaviour of this tag is analog to that of inlineStyles, for javascript assets added with addJs.