Pass in wordpress api details through iframe name instead.

This commit is contained in:
HenriT
2021-08-26 20:16:09 +03:00
parent f45e430d68
commit 9efef166f8
2 changed files with 7 additions and 4 deletions

View File

@ -1,4 +1,3 @@
export default {
storageType: 'local',
wordpress_url: 'http://tih.test/wp-json/wp/v2/',
storageType: 'local'
};

View File

@ -1,9 +1,13 @@
import axios from 'axios';
import { removeVuexORMFlags } from '@/utils/helpers';
import config from '@/config/app.config';
const config = JSON.parse(window.name);
const http = axios.create({
baseURL: config.wordpress_url,
baseURL: config.api_url,
headers: {
'X-WP-Nonce': config.nonce,
},
});
class WordpressAdapter {