Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion apps/oxlint/src-js/plugins/load.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { pathToFileURL } from 'node:url';

import { Context } from './context.js';
import { getErrorMessage } from './utils.js';

Expand Down Expand Up @@ -100,7 +102,7 @@ async function loadPluginImpl(path: string): Promise<PluginDetails> {
throw new Error('This plugin has already been registered. This is a bug in Oxlint. Please report it.');
}

const { default: plugin } = (await import(path)) as { default: Plugin };
const { default: plugin } = (await import(pathToFileURL(path).href)) as { default: Plugin };

registeredPluginPaths.add(path);

Expand Down
Loading