diff --git a/src/server.js b/src/server.js index 2e10714..ae3a19b 100644 --- a/src/server.js +++ b/src/server.js @@ -8,9 +8,13 @@ const app = express(); // Serve static files from the 'src' directory app.use(express.static(path.join(__dirname, ''))); +// Serve app-ads.txt when accessed at the root (/app-ads.txt) +app.get('/app-ads.txt', (req, res) => { + res.sendFile(path.join(__dirname, 'app-ads.txt')); +}); + // Define a route to serve the HTML file app.get('/', (req, res) => { - // Send the HTML file as the response res.sendFile(path.join(__dirname, 'index.html')); });