mirror of
https://github.com/electron-vite/electron-vite-vue
synced 2025-08-27 07:21:18 +08:00
feat: define globalThis.__dirname
This commit is contained in:
@@ -3,8 +3,8 @@ import { release } from 'node:os'
|
|||||||
import { join, dirname } from 'node:path'
|
import { join, dirname } from 'node:path'
|
||||||
import { fileURLToPath } from 'node:url'
|
import { fileURLToPath } from 'node:url'
|
||||||
|
|
||||||
const __filename = fileURLToPath(import.meta.url)
|
globalThis.__filename = fileURLToPath(import.meta.url)
|
||||||
const __dirname = dirname(__filename)
|
globalThis.__dirname = dirname(__filename)
|
||||||
|
|
||||||
// The built directory structure
|
// The built directory structure
|
||||||
//
|
//
|
||||||
|
Reference in New Issue
Block a user