mirror of
https://github.com/litruv/API-WebSocket-Bridge.git
synced 2026-07-24 02:36:03 +10:00
first commit
This commit is contained in:
16
index.js
Normal file
16
index.js
Normal file
@@ -0,0 +1,16 @@
|
||||
const WebSocketDriver = require('./WebSocketDriver');
|
||||
|
||||
// Load the configuration from config.json
|
||||
const config = require('./config.json');
|
||||
|
||||
// Create an instance of WebSocketDriver
|
||||
const driver = new WebSocketDriver(config);
|
||||
|
||||
// Start the WebSocket driver
|
||||
driver.start()
|
||||
.then(() => {
|
||||
driver.log('WebSocket driver is running', 'info');
|
||||
})
|
||||
.catch((error) => {
|
||||
driver.log(`Failed to start WebSocket driver: ${error.message}`, 'error');
|
||||
});
|
||||
Reference in New Issue
Block a user