diff --git a/routing.rst b/routing.rst index 9bd09e531cc..75755c31d40 100644 --- a/routing.rst +++ b/routing.rst @@ -1917,7 +1917,7 @@ Generating URLs in JavaScript If your JavaScript code is included in a Twig template, you can use the ``path()`` and ``url()`` Twig functions to generate the URLs and store them in -JavaScript variables. The ``escape()`` function is needed to escape any +JavaScript variables. The ``escape()`` filter is needed to escape any non-JavaScript-safe values: .. code-block:: html+twig