Support » Plugin: WP-Paginate » jQuery.fn.click() event shorthand is deprecated

  • ODAK71

    (@odak71)


    Hello,

    For wordpress 5.7 and jquery 3.5.1 compatibility without jquery migrate

    /wp-paginate/js/wp-paginate.js: jQuery.fn.click() event shorthand is deprecated

    JQMIGRATE: jQuery.fn.click() event shorthand is deprecated

    Cause: The .on() and .trigger() methods can set an event handler or generate an event for any event type, and should be used instead of the shortcut methods. This message also applies to the other event shorthands, including: blur, focus, focusin, focusout, resize, scroll, dblclick, mousedown, mouseup, mousemove, mouseover, mouseout, mouseenter, mouseleave, change, select, submit, keydown, keypress, keyup, and contextmenu.

    Solution: Instead of .click(fn) use .on(“click”, fn). Instead of .click() use .trigger(“click”).

    See also:
    https://github.com/jquery/jquery-migrate/blob/master/warnings.md
    https://css-tricks.com/wordpress-5-7-big-ol-jquery-update/`

Viewing 1 replies (of 1 total)
  • Plugin Author AlanP57

    (@alanp57)

    I see what you are saying. We will get a new version of WP Paginate out soon.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.