chore: update min supported node version to >=18 (#19)
Update required minimum node version to >=18 in preparation for updating other dependencies that require newer node versions.
This commit is contained in:
parent
a13295b223
commit
999b9b54a2
9 changed files with 2712 additions and 1745 deletions
|
|
@ -3,11 +3,17 @@
|
|||
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
|
||||
*/
|
||||
|
||||
import { isErrnoException } from "./error";
|
||||
|
||||
const resolveModulePath = (importPath: string): string | undefined => {
|
||||
try {
|
||||
return require.resolve(importPath);
|
||||
} catch (error) {
|
||||
if (error.code === "MODULE_NOT_FOUND") {
|
||||
if (
|
||||
error instanceof Error &&
|
||||
isErrnoException(error) &&
|
||||
error.code === "MODULE_NOT_FOUND"
|
||||
) {
|
||||
return;
|
||||
}
|
||||
throw error;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue