title: adding export script to an existing next.config.js
body: <p>I'm following Microsoft's Tutorial:
  <a href="http://%20https://docs.microsoft.com/en-us/azure/static-web-apps/deploy-nextjs" rel="nofollow noreferrer">Deploy static-rendered Next.js websites on Azure Static Web Apps</a></p>
  <p>The problem is, I'm trying to add to my next.config.js file this code:</p>
  <pre><code>const data = require('./utils/projectsData');
  
  module.exports = {
    trailingSlash: true,
    exportPathMap: async function () {
      const { projects } = data;
      const paths = {
        '/': { page: '/' },
      };
  
      projects.forEach((project) =&gt; {
        paths[`/project/${project.slug}`] = {
          page: '/project/[path]',
          query: { path: project.slug },
        };
      });
  
      return paths;
    },
  };
  </code></pre>
  <p>but my next.config.js already has some existing content:</p>
  <pre><code>require('dotenv').config()
  
  const withFonts = require('next-fonts')
  
  module.exports = withFonts({
    serverRuntimeConfig: {},
    trailingSlash: true,
    exportPathMap: function() {
      return {
        '/': { page: '/' }
      };
    },
    publicRuntimeConfig: {
      API_URL: process.env.API_URL,
      PORT: process.env.PORT || 3000,
      PUBLISHABLE_KEY: process.env.PUBLISHABLE_KEY,
    },
  })
  </code></pre>
  <p>how can I combine them?</p>