diff --git a/spotify-recent-oauth.php b/spotify-recent-oauth.php index 7b11816..b05397e 100644 --- a/spotify-recent-oauth.php +++ b/spotify-recent-oauth.php @@ -26,10 +26,16 @@ function sro_register_block() { 'editor_script' => 'sro-block-js', 'render_callback' => 'sro_render_block' )); - wp_register_style('sro-style',plugins_url('css/style.css',__FILE__)); } add_action('init', 'sro_register_block'); +function sro_enqueue_styles() { + wp_enqueue_style( + 'sro-style', + plugins_url('css/style.css', __FILE__) + ); +} +add_action('wp_enqueue_scripts', 'sro_enqueue_styles'); /* * Fetch recent track via Spotify API