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
+2 -2
View File
@@ -3,9 +3,9 @@
> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).
```ts
import { ChildProcess } from 'child_process';
import { ChildProcess } from 'node:child_process';
import { CustomErrorBase } from '@backstage/errors';
import { SpawnOptions } from 'child_process';
import { SpawnOptions } from 'node:child_process';
// @public
export const BACKSTAGE_JSON = 'backstage.json';
+1 -1
View File
@@ -14,7 +14,7 @@
* limitations under the License.
*/
import { posix, win32 } from 'path';
import { posix, win32 } from 'node:path';
describe('isChildPath', () => {
it('should check child posix paths', () => {
+2 -2
View File
@@ -20,8 +20,8 @@ import {
resolve as resolvePath,
dirname,
basename,
} from 'path';
import { realpathSync, lstatSync, readlinkSync } from 'fs';
} from 'node:path';
import { realpathSync, lstatSync, readlinkSync } from 'node:fs';
// Resolves a path to its real location, following symlinks.
// Handles cases where the final target doesn't exist by recursively
+1 -1
View File
@@ -15,7 +15,7 @@
*/
/* eslint-disable no-restricted-syntax */
import { resolve as resolvePath } from 'path';
import { resolve as resolvePath } from 'node:path';
import { findPaths, findRootPath, findOwnDir, findOwnRootDir } from './paths';
describe('paths', () => {
+2 -2
View File
@@ -14,8 +14,8 @@
* limitations under the License.
*/
import fs from 'fs';
import { dirname, resolve as resolvePath } from 'path';
import fs from 'node:fs';
import { dirname, resolve as resolvePath } from 'node:path';
/**
* A function that takes a set of path fragments and resolves them into a
+1 -1
View File
@@ -14,7 +14,7 @@
* limitations under the License.
*/
import { ChildProcess, SpawnOptions } from 'child_process';
import { ChildProcess, SpawnOptions } from 'node:child_process';
import spawn from 'cross-spawn';
import { ExitCodeError } from './errors';
import { assertError } from '@backstage/errors';