require the use of node prefix on native imports

Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
Fredrik Adelöw
2026-01-25 13:47:32 +01:00
parent 4ad63b8d9f
commit 7455dae884
444 changed files with 749 additions and 634 deletions
@@ -16,8 +16,8 @@
import { createMockDirectory } from '@backstage/backend-test-utils';
import { collectConfigSchemas, internal } from './collect';
import path from 'path';
import { execSync } from 'child_process';
import path from 'node:path';
import { execSync } from 'node:child_process';
const mockSchema = {
type: 'object',
+2 -2
View File
@@ -15,13 +15,13 @@
*/
import fs from 'fs-extra';
import { EOL } from 'os';
import { EOL } from 'node:os';
import {
resolve as resolvePath,
relative as relativePath,
dirname,
sep,
} from 'path';
} from 'node:path';
import { ConfigSchemaPackageEntry } from './types';
import { JsonObject } from '@backstage/types';
import { assertError } from '@backstage/errors';
@@ -15,7 +15,7 @@
*/
import fs from 'fs-extra';
import { resolve as resolvePath } from 'path';
import { resolve as resolvePath } from 'node:path';
import { ConfigSources } from './ConfigSources';
import { ConfigSource } from './types';
import { MutableConfigSource } from './MutableConfigSource';
@@ -14,7 +14,7 @@
* limitations under the License.
*/
import { resolve as resolvePath } from 'path';
import { resolve as resolvePath } from 'node:path';
import fs from 'fs-extra';
import { Config, ConfigReader } from '@backstage/config';
import parseArgs from 'minimist';
@@ -14,9 +14,9 @@
* limitations under the License.
*/
import os from 'os';
import os from 'node:os';
import fs from 'fs-extra';
import { resolve as resolvePath } from 'path';
import { resolve as resolvePath } from 'node:path';
import { FileConfigSource } from './FileConfigSource';
import { readN } from './__testUtils__/testUtils';
@@ -16,7 +16,12 @@
import chokidar, { FSWatcher } from 'chokidar';
import fs from 'fs-extra';
import { basename, dirname, isAbsolute, resolve as resolvePath } from 'path';
import {
basename,
dirname,
isAbsolute,
resolve as resolvePath,
} from 'node:path';
import {
AsyncConfigSourceGenerator,
ConfigSource,
@@ -14,8 +14,8 @@
* limitations under the License.
*/
import * as os from 'os';
import { resolve as resolvePath } from 'path';
import * as os from 'node:os';
import { resolve as resolvePath } from 'node:path';
import { createIncludeTransform } from './include';
import { TransformFunc } from './types';
@@ -15,7 +15,7 @@
*/
import yaml from 'yaml';
import { extname, dirname, resolve as resolvePath } from 'path';
import { extname, dirname, resolve as resolvePath } from 'node:path';
import { JsonObject, JsonValue } from '@backstage/types';
import { isObject } from './utils';
import { TransformFunc, ReadFileFunc } from './types';