Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
moroi committed Dec 9, 2017
0 parents commit e2fd0f3
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 0 deletions.
13 changes: 13 additions & 0 deletions functions.php
@@ -0,0 +1,13 @@
<?php
add_theme_support('post-thumbnails', array('post'));
add_theme_support('menus');

function my_customize_rest_cors() {
remove_filter( 'rest_pre_serve_request', 'rest_send_cors_headers' );
add_filter( 'rest_pre_serve_request', function( $value ) {
header( 'Access-Control-Allow-Origin: *' );
return $value;
});
}
add_action( 'rest_api_init', 'my_customize_rest_cors', 15 );
?>
Empty file added index.php
Empty file.
9 changes: 9 additions & 0 deletions style.css
@@ -0,0 +1,9 @@
/*
Theme Name: Headless WordPress
Author: Reparade
Author URI: https://reparede.com/
Description: Starter theme for Headless CMS.
Version: 1.0
License: GNU General Public License v3 or later
License URI: https://www.gnu.org/licenses/gpl-3.0.html
*/

0 comments on commit e2fd0f3

Please sign in to comment.