Breaking: Replace StandaloneView with ViewFactory
Description
The Fluid Standalone is deprecated since TYPO3 v13 and will be
removed in TYPO3 v14. \Extcode\ creates its
views via \TYPO3\ now. The view factory
is injected into \Extcode\ and handed over to
the Tcpdf.
This changes the public API of Tcpdf:
Tcpdfis renamed toWrapper:: get Standalone View () Tcpdf. It returns aWrapper:: create View () \TYPO3\instead of aCMS\ Core\ View\ View Interface \TYPO3\.CMS\ Fluid\ View\ Standalone View Tcpdfis renamed toWrapper:: render Standalone View () Tcpdf. The arguments are unchanged.Wrapper:: render View () - The constructor and
Tcpdfexpect aWrapper:: create With Type And Settings () \TYPO3\as first argument.CMS\ Core\ View\ View Factory Interface
The template resolution via the TypoScript settings view.,
view. and view. is unchanged. The
rendered documents do not change.
Affected Installations
Installations which create a Tcpdf or call
Tcpdf or
Tcpdf in their own code, e.g. in an own
implementation of \Extcode\
or in a class extending Tcpdf.
Installations which configure the documents via TypoScript and templates only are not affected.
Migration
- Inject
\TYPO3\and pass it as first argument toCMS\ Core\ View\ View Factory Interface new TcpdforWrapper () Tcpdf.Wrapper:: create With Type And Settings () - Replace calls of
getwithStandalone View () create. Use only the methods ofView () \TYPO3\(CMS\ Core\ View\ View Interface assign,() assign,Multiple () render) on the returned view and adapt type hints accordingly.() - Replace calls of
renderwithStandalone View () render.View ()