
- Change to ../../../index.js to account for dist/server/chunks/ depth - Resolves module not found error in production build
33 lines
777 B
JavaScript
33 lines
777 B
JavaScript
// First, rename the CommonJS file to .cjs
|
|
import { createRequire } from 'module';
|
|
const require = createRequire(import.meta.url);
|
|
|
|
// Require the CommonJS module
|
|
const nativeBindings = require('../../../index.js');
|
|
|
|
export const {
|
|
getChurchName,
|
|
fetchEventsJson,
|
|
fetchFeaturedEventsJson,
|
|
fetchSermonsJson,
|
|
fetchLivestreamArchiveJson,
|
|
fetchConfigJson,
|
|
getMissionStatement,
|
|
fetchRandomBibleVerseJson,
|
|
getStreamLiveStatus,
|
|
getLivestreamUrl,
|
|
getChurchAddress,
|
|
getChurchPhysicalAddress,
|
|
getChurchPoBox,
|
|
getContactPhone,
|
|
getContactEmail,
|
|
getFacebookUrl,
|
|
getYoutubeUrl,
|
|
getInstagramUrl,
|
|
submitContactV2Json,
|
|
validateContactFormJson,
|
|
fetchBulletinsJson,
|
|
fetchCurrentBulletinJson,
|
|
fetchBibleVerseJson,
|
|
submitEventJson
|
|
} = nativeBindings; |