import apiFetch from '@wordpress/api-fetch';

const namespace = () =>
	window.CLIQTHEMES_UI?.app?.adminNamespace || 'cliq-store-locator/v1';

export const adminGet = ( path ) =>
	apiFetch( { path: `/${ namespace() }/admin/${ path }` } );
