File tree Expand file tree Collapse file tree 2 files changed +8
-3
lines changed
Expand file tree Collapse file tree 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 11{
22 "extends": ["airbnb-base", "plugin:redos/recommended"],
33 "globals": {
4- "globalThis": true
4+ "globalThis": true,
5+ "navigator": true
56 },
67 "rules": {
78 "no-empty": ["error", { "allowEmptyCatch": true }],
Original file line number Diff line number Diff line change 22// eslint-disable-next-line import/order
33import * as attention from './helpers/attention.js' ;
44
5+ const deno = typeof Deno !== 'undefined' ;
6+ const bun = typeof Bun !== 'undefined' ;
7+ const workerd = navigator . userAgent === 'Cloudflare-Workers' ;
8+
59const minimal = 'Jod' ;
6- const { lts : codename } = process . release || { } ;
7- if ( ! codename || codename . charCodeAt ( 0 ) < minimal . charCodeAt ( 0 ) || typeof Bun !== 'undefined' || typeof Deno !== 'undefined' ) {
10+ const release = globalThis . process ? .release ;
11+ if ( ! release ?. lts || release ?. lts . charCodeAt ( 0 ) < minimal . charCodeAt ( 0 ) || deno || bun || workerd ) {
812 attention . warn ( 'Unsupported runtime. Use Node.js v22.x LTS, or a later LTS release.' ) ;
913}
1014
You can’t perform that action at this time.
0 commit comments