diff --git a/typo3/sysext/core/Documentation/Changelog/master/Deprecation-83806-DeprecatePagejavascriptLibsAndPagejavascriptLibsjQuery.rst b/typo3/sysext/core/Documentation/Changelog/master/Deprecation-83806-DeprecatePagejavascriptLibsAndPagejavascriptLibsjQuery.rst new file mode 100644 index 0000000000000000000000000000000000000000..7ab2c218444d3eb5ce8f4f7fd0e5e25ff88996ef --- /dev/null +++ b/typo3/sysext/core/Documentation/Changelog/master/Deprecation-83806-DeprecatePagejavascriptLibsAndPagejavascriptLibsjQuery.rst @@ -0,0 +1,39 @@ +.. include:: ../../Includes.txt + +================================================================================== +Deprecation: #83806 - Deprecate page.javascriptLibs and page.javascriptLibs.jQuery +================================================================================== + +See :issue:`83806` + +Description +=========== + +The settings :typoscript:`page.javascriptLibs` and :typoscript:`page.javascriptLibs.jQuery` have been marked as deprecated and will be removed in CMS 10. + + +Impact +====== + +Installations that use :typoscript:`page.javascriptLibs` or :typoscript:`page.javascriptLibs.jQuery` will trigger a deprecation warning. + + +Affected Installations +====================== + +All installations that use one of the above settings. + + +Migration +========= + +Use one of the following settings to add jQuery: + +* :typoscript:`page.includeJSLibs` +* :typoscript:`page.includeJSFooterlibs` +* :typoscript:`page.includeJS` +* :typoscript:`page.includeJSFooter` +* :typoscript:`page.headerData` +* :typoscript:`page.footerData` + +.. index:: Frontend, TypoScript, NotScanned diff --git a/typo3/sysext/frontend/Classes/Page/PageGenerator.php b/typo3/sysext/frontend/Classes/Page/PageGenerator.php index d4a4917d1c089923cf1384da574771e4662a9717..95b9fb9ee61c766f3e5bc7fd2e6915be8906c605 100644 --- a/typo3/sysext/frontend/Classes/Page/PageGenerator.php +++ b/typo3/sysext/frontend/Classes/Page/PageGenerator.php @@ -351,8 +351,14 @@ class PageGenerator } // Javascript Libraries if (is_array($tsfe->pSetup['javascriptLibs.'])) { + // @deprecated since TYPO3 v9, will be removed in TYPO3 v10, the setting page.javascriptLibs has been deprecated and will be removed in TYPO3 CMS 10. + trigger_error('The setting page.javascriptLibs has been deprecated and will be removed in TYPO3 CMS 10', E_USER_DEPRECATED); + // Include jQuery into the page renderer if (!empty($tsfe->pSetup['javascriptLibs.']['jQuery'])) { + // @deprecated since TYPO3 v9, will be removed in TYPO3 v10, the setting page.javascriptLibs.jQuery has been deprecated and will be removed in TYPO3 CMS 10. + trigger_error('The setting page.javascriptLibs.jQuery has been deprecated and will be removed in TYPO3 CMS 10', E_USER_DEPRECATED); + $jQueryTS = $tsfe->pSetup['javascriptLibs.']['jQuery.']; // Check if version / source is set, if not set variable to "NULL" to use the default of the page renderer $version = $jQueryTS['version'] ?? null; diff --git a/typo3/sysext/t3editor/Resources/Private/tsref.xml b/typo3/sysext/t3editor/Resources/Private/tsref.xml index dc5c4313cb10b3e7403cdfb7642f11f81242e61e..dc1249f783a56070b956898199b642ddd9c70f16 100644 --- a/typo3/sysext/t3editor/Resources/Private/tsref.xml +++ b/typo3/sysext/t3editor/Resources/Private/tsref.xml @@ -5127,18 +5127,6 @@ page.inlineSettings { will produce following source: TYPO3.settings = {"TS":{"setting1":"Hello","setting2":"GoOnTop"}}; -]]></description> - <default><![CDATA[ -]]></default> - </property> - <property name="javascriptLibs" type="array"> - <description><![CDATA[array of Strings - This allows to include the JavaScript libraries that are shipped with the TYPO3 Core. - -javascriptLibs { - # includes jQuery - jQuery = 1 -} ]]></description> <default><![CDATA[ ]]></default>