ns-rx / poetwp

0 stars 0 forks source link

Refactor datepicker JS #23

Open ns-rx opened 3 months ago

ns-rx commented 3 months ago
          Rather than adding a block of JS, consider using `wp_add_inline_script()` function call that references an enqueued script, so that it only gets printed out if the script was indeed output.

You might also like to avoid hard-coding a dateFormat and use the date format already stored in the WP settings for consistency.

_Originally posted by @GaryJones in https://github.com/ns-rx/poetwp/pull/13#discussion_r1730400258_