Skip to content

Instantly share code, notes, and snippets.

@billrobbins
Created November 19, 2018 12:57
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save billrobbins/1ef40676ecbc1db863601e38bdf4ac8d to your computer and use it in GitHub Desktop.
$url = trailingslashit( get_site_url() );
wp_localize_script('app', 'baseURL', array(
'url' => $url
)
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment