Skip to content

Commit

Permalink
add server zone config
Browse files Browse the repository at this point in the history
  • Loading branch information
tyiuhc committed Jan 3, 2025
1 parent b7a4cb1 commit 2231792
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions packages/experiment-tag/src/script.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,11 @@ import { initializeExperiment } from './experiment';

const API_KEY = '{{DEPLOYMENT_KEY}}';
const initialFlags = '{{INITIAL_FLAGS}}';
initializeExperiment(API_KEY, initialFlags).then(() => {
// Remove anti-flicker css if it exists
document.getElementById('amp-exp-css')?.remove();
});
const serverZone = '{{SERVER_ZONE}}';

initializeExperiment(API_KEY, initialFlags, { serverZone: serverZone }).then(
() => {
// Remove anti-flicker css if it exists
document.getElementById('amp-exp-css')?.remove();
},
);

0 comments on commit 2231792

Please sign in to comment.