From bb4861b9b91950d6b4f4bb6871b19afd63bf535b Mon Sep 17 00:00:00 2001 From: Yonel Ceruto Date: Tue, 16 Oct 2018 08:27:51 -0400 Subject: [PATCH] Add some notes about trigger deprecation --- components/options_resolver.rst | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/components/options_resolver.rst b/components/options_resolver.rst index 87829813b17..b19869a754a 100644 --- a/components/options_resolver.rst +++ b/components/options_resolver.rst @@ -654,6 +654,12 @@ method:: ->setDeprecated('hostname', 'The option "hostname" is deprecated, use "host" instead.') ; +.. note:: + + The deprecation message will be triggered only if the option is being used + somewhere, either its value is provided by the user or the option is evaluated + within closures of lazy options and normalizers. + Instead of passing the message, you may also pass a closure which returns a string (the deprecation message) or an empty string to ignore the deprecation. This closure is useful to only deprecate some of the allowed types or values of @@ -677,6 +683,11 @@ the option:: }) ; +.. note:: + + Deprecation based on the value is triggered only when the option is provided + by the user. + This closure receives as argument the value of the option after validating it and before normalizing it when the option is being resolved. pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy