chore(lint): no-named-as-default use named imports for ws and openai

This commit is contained in:
Mohamed Boudra
2026-04-24 07:15:26 +07:00
parent 31d24ed216
commit 38efad7db2
12 changed files with 12 additions and 12 deletions

View File

@@ -1,4 +1,4 @@
import WebSocket from "ws"; import { WebSocket } from "ws";
interface WebSocketLike { interface WebSocketLike {
readyState: number; readyState: number;

View File

@@ -2,7 +2,7 @@ import "dotenv/config";
import { writeFile, mkdir } from "node:fs/promises"; import { writeFile, mkdir } from "node:fs/promises";
import path from "node:path"; import path from "node:path";
import { fileURLToPath } from "node:url"; import { fileURLToPath } from "node:url";
import OpenAI from "openai"; import { OpenAI } from "openai";
function requireEnv(name: string): string { function requireEnv(name: string): string {
const value = process.env[name]; const value = process.env[name];

View File

@@ -3,7 +3,7 @@ import { homedir, tmpdir } from "node:os";
import path from "node:path"; import path from "node:path";
import pino from "pino"; import pino from "pino";
import { beforeAll, beforeEach, describe, expect, test } from "vitest"; import { beforeAll, beforeEach, describe, expect, test } from "vitest";
import WebSocket from "ws"; import { WebSocket } from "ws";
import { ClaudeAgentClient } from "../agent/providers/claude-agent.js"; import { ClaudeAgentClient } from "../agent/providers/claude-agent.js";
import { DaemonClient } from "../test-utils/daemon-client.js"; import { DaemonClient } from "../test-utils/daemon-client.js";
import { createTestPaseoDaemon } from "../test-utils/paseo-daemon.js"; import { createTestPaseoDaemon } from "../test-utils/paseo-daemon.js";

View File

@@ -1,5 +1,5 @@
import { describe, expect, test } from "vitest"; import { describe, expect, test } from "vitest";
import WebSocket from "ws"; import { WebSocket } from "ws";
import pino from "pino"; import pino from "pino";
import { Writable } from "node:stream"; import { Writable } from "node:stream";
import net from "node:net"; import net from "node:net";

View File

@@ -2,7 +2,7 @@ import { afterEach, beforeEach, describe, expect, test } from "vitest";
import { mkdtempSync, rmSync } from "fs"; import { mkdtempSync, rmSync } from "fs";
import { tmpdir } from "os"; import { tmpdir } from "os";
import path from "path"; import path from "path";
import WebSocket from "ws"; import { WebSocket } from "ws";
import { DaemonClient } from "../../client/daemon-client.js"; import { DaemonClient } from "../../client/daemon-client.js";
import { import {
WSOutboundMessageSchema, WSOutboundMessageSchema,

View File

@@ -1,6 +1,6 @@
/// <reference lib="dom" /> /// <reference lib="dom" />
import { EventEmitter } from "node:events"; import { EventEmitter } from "node:events";
import WebSocket from "ws"; import { WebSocket } from "ws";
import type pino from "pino"; import type pino from "pino";
import { import {
createDaemonChannel, createDaemonChannel,

View File

@@ -2,7 +2,7 @@ import { it, expect, afterEach } from "vitest";
import http from "node:http"; import http from "node:http";
import net from "node:net"; import net from "node:net";
import express from "express"; import express from "express";
import WebSocket, { WebSocketServer } from "ws"; import { WebSocket, WebSocketServer } from "ws";
import pino from "pino"; import pino from "pino";
import { import {
ScriptRouteStore, ScriptRouteStore,

View File

@@ -1,5 +1,5 @@
import type pino from "pino"; import type pino from "pino";
import WebSocket from "ws"; import { WebSocket } from "ws";
import { EventEmitter } from "node:events"; import { EventEmitter } from "node:events";
import type { StreamingTranscriptionSession } from "../../speech-provider.js"; import type { StreamingTranscriptionSession } from "../../speech-provider.js";

View File

@@ -1,6 +1,6 @@
import { EventEmitter } from "node:events"; import { EventEmitter } from "node:events";
import type pino from "pino"; import type pino from "pino";
import OpenAI from "openai"; import { OpenAI } from "openai";
import { writeFile, unlink } from "fs/promises"; import { writeFile, unlink } from "fs/promises";
import { join } from "path"; import { join } from "path";
import { tmpdir } from "os"; import { tmpdir } from "os";

View File

@@ -1,5 +1,5 @@
import type pino from "pino"; import type pino from "pino";
import OpenAI from "openai"; import { OpenAI } from "openai";
import { Readable } from "node:stream"; import { Readable } from "node:stream";
import type { SpeechStreamResult, TextToSpeechProvider } from "../../speech-provider.js"; import type { SpeechStreamResult, TextToSpeechProvider } from "../../speech-provider.js";

View File

@@ -1,4 +1,4 @@
import WebSocket from "ws"; import { WebSocket } from "ws";
import { import {
DaemonClient as SharedDaemonClient, DaemonClient as SharedDaemonClient,
type DaemonClientConfig as SharedDaemonClientConfig, type DaemonClientConfig as SharedDaemonClientConfig,

View File

@@ -1,7 +1,7 @@
import { mkdtempSync, writeFileSync, rmSync, existsSync } from "node:fs"; import { mkdtempSync, writeFileSync, rmSync, existsSync } from "node:fs";
import { tmpdir } from "node:os"; import { tmpdir } from "node:os";
import path from "node:path"; import path from "node:path";
import OpenAI from "openai"; import { OpenAI } from "openai";
export function requireEnv(name: string): string { export function requireEnv(name: string): string {
const value = process.env[name]; const value = process.env[name];