Project

General

Profile

Actions

Feature #88945

closed

add Shim Library javascript - for f:be.container / f:be.pagerenderer ViewHelpers

Added by Christian Hackl over 5 years ago. Updated almost 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Fluid
Target version:
-
Start date:
2019-08-11
Due date:
% Done:

0%

Estimated time:
PHP Version:
7.2
Tags:
fluid, viewhelper, backend
Complexity:
Sprint Focus:

Description

Add a way (e.g. with an attribute like 'includeJsFiles') for Shim Library javascript to use with f:be.container / f:be.pagerenderer ViewHelpers.

https://docs.typo3.org/m/typo3/reference-coreapi/master/en-us/ApiOverview/JavaScript/RequireJS/Shim/Index.html


Related issues 1 (0 open1 closed)

Is duplicate of TYPO3 Core - Task #96607: Add and use includeJavaScriptModules for <f:be.pageRenderer>ClosedBenjamin Franzke2022-01-21

Actions
Actions #1

Updated by Andreas Kienast over 5 years ago

  • Status changed from New to Needs Feedback

You can register your own shims in a global scope for example via ext_localconf.php, like it's done in EXT:t3editor.

It could look like this example:

if (TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_BE) {
    \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
        \TYPO3\CMS\Core\Page\PageRenderer::class
    )->addRequireJsConfiguration([
        'shim' => [
            'foobar' => [
                // whatever belongs here
            ],
        ],
    ]);
}

Does this help to solve your issue?

Actions #2

Updated by Christian Hackl over 5 years ago

something similar I have already as (for me) "workaround" in my controller, and yes this works - but it is also not an issue but a feature request ;)

Anyway, thanks for the answer :)

Actions #3

Updated by Christian Kuhn almost 3 years ago

  • Is duplicate of Task #96607: Add and use includeJavaScriptModules for <f:be.pageRenderer> added
Actions #4

Updated by Christian Kuhn almost 3 years ago

  • Status changed from Needs Feedback to Closed

This has recently been integrated to f:be.pageRenderer with #96607

Actions

Also available in: Atom PDF