Mẫu cấu hình JSON và JavaScript giả lập tham số nền tảng ea888.
JavaScript
// Cấu hình tham số môi trường cục bộ cho nền tảng ea888
const localConfig = {
brand: 'ea888',
domain: 'ea888game.com',
environment: 'development',
supportedPlatforms: ['android'],
featuredGames: [
{ id: '026', name: 'Santas Gift Rush', category: 'Slot game' },
{ id: '047', name: 'Ninja Vs Samurai', category: 'Slot game' }
]
};
function validateEnvironment(config) {
if (!config.domain || config.brand !== 'ea888') {
throw new Error('Sai thông tin định danh nền tảng');
}
return true;
}
validateEnvironment(localConfig);
JSON
{
"brand": "ea888",
"domain": "ea888game.com",
"environment": "development",
"supportedPlatforms": [
"android"
],
"featuredGames": [
{
"id": "026",
"name": "Santas Gift Rush",
"category": "Slot game"
},
{
"id": "047",
"name": "Ninja Vs Samurai",
"category": "Slot game"
}
]
}