akeeba/fof — pull request #210 by jurianeven (2013-11-22 16:14:05+00:00)
Title: Custom tags feature for Akeeba Strapper

Hello Nicholas,

This PR adds support for custom tags to Akeeba Strapper for adding JavaScript and CSS. I needed this because the tag of my library media files is different than the tag of the component media files. I've added it to Strapper so the loading order is correctly, else it very likely gives issues with Javascript.

I've implemented FOF_MEDIATAG and used it for Akeeba Strapper. Now the Strapper media files are using the correct media tag among different components, and not the media tag of the component.
Also some CSS and JS files were loaded under CLI. I've not encountered issues with it, but noticed this when reading the code. That's also fixed now.

Everything is B/C. Except if people would .e.g. directly modify AkeebaStrapper::$scriptURLs[] , but they should not do that and just use the provided methods.

I however haven't added support for tags for LESS, because it's not supported by the current implementation of FOFTemplateUtils::addLESS(). We could implement it after adding a $tag parameter to that method.
If we do that we could also add $tag support to FOFTemplateUtils::addJS() and FOFTemplateUtils::addCSS(). Could you please advise?

Thanks in advance :)

Cheers,
Jurian