From 834752c0faf8c0c98bf81e37723d054bd39c9785 Mon Sep 17 00:00:00 2001 From: yann300 Date: Mon, 3 Jun 2024 12:20:05 +0200 Subject: [PATCH] use export keyword --- libs/remix-simulator/bin/ethsim | 2 +- libs/remix-simulator/src/index.ts | 2 +- libs/remix-simulator/src/server.ts | 3 +-- 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/libs/remix-simulator/bin/ethsim b/libs/remix-simulator/bin/ethsim index 814e2a6a46..95e5ab879d 100755 --- a/libs/remix-simulator/bin/ethsim +++ b/libs/remix-simulator/bin/ethsim @@ -32,7 +32,7 @@ program console.log('details: ', option.details) console.log('host: ', option.ip) console.log('port: ', option.port) - const Server = require('../src/server') + const { Server } = require('../src/server') const server = new Server({ coinbase: option.coinbase, rpc: option.rpc, diff --git a/libs/remix-simulator/src/index.ts b/libs/remix-simulator/src/index.ts index 038ef9308e..35835a8ee2 100644 --- a/libs/remix-simulator/src/index.ts +++ b/libs/remix-simulator/src/index.ts @@ -1,2 +1,2 @@ export { Provider, extend, JSONRPCRequestPayload, JSONRPCResponsePayload, JSONRPCResponseCallback } from './provider' -export * as Server from './server' +export { Server } from './server' diff --git a/libs/remix-simulator/src/server.ts b/libs/remix-simulator/src/server.ts index 2c3a2f9f5e..70c32fbaf5 100644 --- a/libs/remix-simulator/src/server.ts +++ b/libs/remix-simulator/src/server.ts @@ -6,7 +6,7 @@ import { Provider, ProviderOptions } from './provider' import { log } from './utils/logs' const app = express() -class Server { +export class Server { provider rpcOnly @@ -68,4 +68,3 @@ class Server { } } -module.exports = Server