chore: Use ES modules for backend app

This commit is contained in:
Faruk AYDIN
2024-01-05 19:08:04 +01:00
parent 43dba351c3
commit b2f8634008
97 changed files with 286 additions and 275 deletions

View File

@@ -1,7 +1,7 @@
import { Router } from 'express';
import graphQLInstance from '../helpers/graphql-instance';
import webhooksRouter from './webhooks';
import paddleRouter from './paddle.ee';
import graphQLInstance from '../helpers/graphql-instance.js';
import webhooksRouter from './webhooks.js';
import paddleRouter from './paddle.ee.js';
const router = Router();

View File

@@ -1,5 +1,5 @@
import { Router } from 'express';
import webhooksHandler from '../controllers/paddle/webhooks.ee';
import webhooksHandler from '../controllers/paddle/webhooks.ee.js';
const router = Router();

View File

@@ -1,9 +1,9 @@
import express, { Router } from 'express';
import multer from 'multer';
import appConfig from '../config/app';
import webhookHandlerByFlowId from '../controllers/webhooks/handler-by-flow-id';
import webhookHandlerByConnectionIdAndRefValue from '../controllers/webhooks/handler-by-connection-id-and-ref-value';
import appConfig from '../config/app.js';
import webhookHandlerByFlowId from '../controllers/webhooks/handler-by-flow-id.js';
import webhookHandlerByConnectionIdAndRefValue from '../controllers/webhooks/handler-by-connection-id-and-ref-value.js';
const router = Router();
const upload = multer();