No ticket. Abstract conditional hook definition.

Shaves off 14 bytes minified gzipped.

The mechanism used to define hooks requiring lazy supports is repeated: first define the hook unconditionally as a function first executing the support test and later either removing itself or redefining to just execute the hook function without repeating executing support tests.

Analogous PR for `1.x-master`: #1356.